1. Packages
  2. AWS Classic
  3. API Docs
  4. efs
  5. getMountTarget

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.12.2 published on Wednesday, Nov 29, 2023 by Pulumi

aws.efs.getMountTarget

Explore with Pulumi AI

aws logo

Try AWS Native preview for resources not in the classic version.

AWS Classic v6.12.2 published on Wednesday, Nov 29, 2023 by Pulumi

    Provides information about an Elastic File System Mount Target (EFS).

    Example Usage

    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Aws = Pulumi.Aws;
    
    return await Deployment.RunAsync(() => 
    {
        var config = new Config();
        var mountTargetId = config.Get("mountTargetId") ?? "";
        var byId = Aws.Efs.GetMountTarget.Invoke(new()
        {
            MountTargetId = mountTargetId,
        });
    
    });
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/efs"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		cfg := config.New(ctx, "")
    		mountTargetId := ""
    		if param := cfg.Get("mountTargetId"); param != "" {
    			mountTargetId = param
    		}
    		_, err := efs.LookupMountTarget(ctx, &efs.LookupMountTargetArgs{
    			MountTargetId: pulumi.StringRef(mountTargetId),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.aws.efs.EfsFunctions;
    import com.pulumi.aws.efs.inputs.GetMountTargetArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            final var config = ctx.config();
            final var mountTargetId = config.get("mountTargetId").orElse("");
            final var byId = EfsFunctions.getMountTarget(GetMountTargetArgs.builder()
                .mountTargetId(mountTargetId)
                .build());
    
        }
    }
    
    import pulumi
    import pulumi_aws as aws
    
    config = pulumi.Config()
    mount_target_id = config.get("mountTargetId")
    if mount_target_id is None:
        mount_target_id = ""
    by_id = aws.efs.get_mount_target(mount_target_id=mount_target_id)
    
    import * as pulumi from "@pulumi/pulumi";
    import * as aws from "@pulumi/aws";
    
    const config = new pulumi.Config();
    const mountTargetId = config.get("mountTargetId") || "";
    const byId = aws.efs.getMountTarget({
        mountTargetId: mountTargetId,
    });
    
    configuration:
      mountTargetId:
        type: string
        default:
    variables:
      byId:
        fn::invoke:
          Function: aws:efs:getMountTarget
          Arguments:
            mountTargetId: ${mountTargetId}
    

    Using getMountTarget

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getMountTarget(args: GetMountTargetArgs, opts?: InvokeOptions): Promise<GetMountTargetResult>
    function getMountTargetOutput(args: GetMountTargetOutputArgs, opts?: InvokeOptions): Output<GetMountTargetResult>
    def get_mount_target(access_point_id: Optional[str] = None,
                         file_system_id: Optional[str] = None,
                         mount_target_id: Optional[str] = None,
                         opts: Optional[InvokeOptions] = None) -> GetMountTargetResult
    def get_mount_target_output(access_point_id: Optional[pulumi.Input[str]] = None,
                         file_system_id: Optional[pulumi.Input[str]] = None,
                         mount_target_id: Optional[pulumi.Input[str]] = None,
                         opts: Optional[InvokeOptions] = None) -> Output[GetMountTargetResult]
    func LookupMountTarget(ctx *Context, args *LookupMountTargetArgs, opts ...InvokeOption) (*LookupMountTargetResult, error)
    func LookupMountTargetOutput(ctx *Context, args *LookupMountTargetOutputArgs, opts ...InvokeOption) LookupMountTargetResultOutput

    > Note: This function is named LookupMountTarget in the Go SDK.

    public static class GetMountTarget 
    {
        public static Task<GetMountTargetResult> InvokeAsync(GetMountTargetArgs args, InvokeOptions? opts = null)
        public static Output<GetMountTargetResult> Invoke(GetMountTargetInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetMountTargetResult> getMountTarget(GetMountTargetArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: aws:efs/getMountTarget:getMountTarget
      arguments:
        # arguments dictionary

    The following arguments are supported:

    AccessPointId string

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    FileSystemId string

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    MountTargetId string

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    AccessPointId string

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    FileSystemId string

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    MountTargetId string

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    accessPointId String

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    fileSystemId String

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    mountTargetId String

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    accessPointId string

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    fileSystemId string

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    mountTargetId string

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    access_point_id str

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    file_system_id str

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    mount_target_id str

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    accessPointId String

    ID or ARN of the access point whose mount target that you want to find. It must be included if a file_system_id and mount_target_id are not included.

    fileSystemId String

    ID or ARN of the file system whose mount target that you want to find. It must be included if an access_point_id and mount_target_id are not included.

    mountTargetId String

    ID or ARN of the mount target that you want to find. It must be included in your request if an access_point_id and file_system_id are not included.

    getMountTarget Result

    The following output properties are available:

    AvailabilityZoneId string

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    AvailabilityZoneName string

    The name of the Availability Zone (AZ) that the mount target resides in.

    DnsName string

    DNS name for the EFS file system.

    FileSystemArn string

    Amazon Resource Name of the file system for which the mount target is intended.

    FileSystemId string
    Id string

    The provider-assigned unique ID for this managed resource.

    IpAddress string

    Address at which the file system may be mounted via the mount target.

    MountTargetDnsName string

    The DNS name for the given subnet/AZ per documented convention.

    MountTargetId string
    NetworkInterfaceId string

    The ID of the network interface that Amazon EFS created when it created the mount target.

    OwnerId string

    AWS account ID that owns the resource.

    SecurityGroups List<string>

    List of VPC security group IDs attached to the mount target.

    SubnetId string

    ID of the mount target's subnet.

    AccessPointId string
    AvailabilityZoneId string

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    AvailabilityZoneName string

    The name of the Availability Zone (AZ) that the mount target resides in.

    DnsName string

    DNS name for the EFS file system.

    FileSystemArn string

    Amazon Resource Name of the file system for which the mount target is intended.

    FileSystemId string
    Id string

    The provider-assigned unique ID for this managed resource.

    IpAddress string

    Address at which the file system may be mounted via the mount target.

    MountTargetDnsName string

    The DNS name for the given subnet/AZ per documented convention.

    MountTargetId string
    NetworkInterfaceId string

    The ID of the network interface that Amazon EFS created when it created the mount target.

    OwnerId string

    AWS account ID that owns the resource.

    SecurityGroups []string

    List of VPC security group IDs attached to the mount target.

    SubnetId string

    ID of the mount target's subnet.

    AccessPointId string
    availabilityZoneId String

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    availabilityZoneName String

    The name of the Availability Zone (AZ) that the mount target resides in.

    dnsName String

    DNS name for the EFS file system.

    fileSystemArn String

    Amazon Resource Name of the file system for which the mount target is intended.

    fileSystemId String
    id String

    The provider-assigned unique ID for this managed resource.

    ipAddress String

    Address at which the file system may be mounted via the mount target.

    mountTargetDnsName String

    The DNS name for the given subnet/AZ per documented convention.

    mountTargetId String
    networkInterfaceId String

    The ID of the network interface that Amazon EFS created when it created the mount target.

    ownerId String

    AWS account ID that owns the resource.

    securityGroups List<String>

    List of VPC security group IDs attached to the mount target.

    subnetId String

    ID of the mount target's subnet.

    accessPointId String
    availabilityZoneId string

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    availabilityZoneName string

    The name of the Availability Zone (AZ) that the mount target resides in.

    dnsName string

    DNS name for the EFS file system.

    fileSystemArn string

    Amazon Resource Name of the file system for which the mount target is intended.

    fileSystemId string
    id string

    The provider-assigned unique ID for this managed resource.

    ipAddress string

    Address at which the file system may be mounted via the mount target.

    mountTargetDnsName string

    The DNS name for the given subnet/AZ per documented convention.

    mountTargetId string
    networkInterfaceId string

    The ID of the network interface that Amazon EFS created when it created the mount target.

    ownerId string

    AWS account ID that owns the resource.

    securityGroups string[]

    List of VPC security group IDs attached to the mount target.

    subnetId string

    ID of the mount target's subnet.

    accessPointId string
    availability_zone_id str

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    availability_zone_name str

    The name of the Availability Zone (AZ) that the mount target resides in.

    dns_name str

    DNS name for the EFS file system.

    file_system_arn str

    Amazon Resource Name of the file system for which the mount target is intended.

    file_system_id str
    id str

    The provider-assigned unique ID for this managed resource.

    ip_address str

    Address at which the file system may be mounted via the mount target.

    mount_target_dns_name str

    The DNS name for the given subnet/AZ per documented convention.

    mount_target_id str
    network_interface_id str

    The ID of the network interface that Amazon EFS created when it created the mount target.

    owner_id str

    AWS account ID that owns the resource.

    security_groups Sequence[str]

    List of VPC security group IDs attached to the mount target.

    subnet_id str

    ID of the mount target's subnet.

    access_point_id str
    availabilityZoneId String

    The unique and consistent identifier of the Availability Zone (AZ) that the mount target resides in.

    availabilityZoneName String

    The name of the Availability Zone (AZ) that the mount target resides in.

    dnsName String

    DNS name for the EFS file system.

    fileSystemArn String

    Amazon Resource Name of the file system for which the mount target is intended.

    fileSystemId String
    id String

    The provider-assigned unique ID for this managed resource.

    ipAddress String

    Address at which the file system may be mounted via the mount target.

    mountTargetDnsName String

    The DNS name for the given subnet/AZ per documented convention.

    mountTargetId String
    networkInterfaceId String

    The ID of the network interface that Amazon EFS created when it created the mount target.

    ownerId String

    AWS account ID that owns the resource.

    securityGroups List<String>

    List of VPC security group IDs attached to the mount target.

    subnetId String

    ID of the mount target's subnet.

    accessPointId String

    Package Details

    Repository
    AWS Classic pulumi/pulumi-aws
    License
    Apache-2.0
    Notes

    This Pulumi package is based on the aws Terraform Provider.

    aws logo

    Try AWS Native preview for resources not in the classic version.

    AWS Classic v6.12.2 published on Wednesday, Nov 29, 2023 by Pulumi