AWS Classic

Pulumi Official
Package maintained by Pulumi
v5.10.0 published on Monday, Jul 11, 2022 by Pulumi

FileSystemAssociation

Associate an Amazon FSx file system with the FSx File Gateway. After the association process is complete, the file shares on the Amazon FSx file system are available for access through the gateway. This operation only supports the FSx File Gateway type.

FSx File Gateway requirements.

Required Services Example

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const awsServiceStoragegatewayAmiFILES3Latest = aws.ssm.getParameter({
    name: "/aws/service/storagegateway/ami/FILE_S3/latest",
});
const testInstance = new aws.ec2.Instance("testInstance", {
    ami: awsServiceStoragegatewayAmiFILES3Latest.then(awsServiceStoragegatewayAmiFILES3Latest => awsServiceStoragegatewayAmiFILES3Latest.value),
    associatePublicIpAddress: true,
    instanceType: aws.ec2.instancetype.InstanceType[data.aws_ec2_instance_type_offering.available.instance_type],
    vpcSecurityGroupIds: [aws_security_group.test.id],
    subnetId: aws_subnet.test[0].id,
}, {
    dependsOn: [
        aws_route.test,
        aws_vpc_dhcp_options_association.test,
    ],
});
const testGateway = new aws.storagegateway.Gateway("testGateway", {
    gatewayIpAddress: testInstance.publicIp,
    gatewayName: "test-sgw",
    gatewayTimezone: "GMT",
    gatewayType: "FILE_FSX_SMB",
    smbActiveDirectorySettings: {
        domainName: aws_directory_service_directory.test.name,
        password: aws_directory_service_directory.test.password,
        username: "Admin",
    },
});
const testWindowsFileSystem = new aws.fsx.WindowsFileSystem("testWindowsFileSystem", {
    activeDirectoryId: aws_directory_service_directory.test.id,
    securityGroupIds: [aws_security_group.test.id],
    skipFinalBackup: true,
    storageCapacity: 32,
    subnetIds: [aws_subnet.test[0].id],
    throughputCapacity: 8,
});
const fsx = new aws.storagegateway.FileSystemAssociation("fsx", {
    gatewayArn: testGateway.arn,
    locationArn: testWindowsFileSystem.arn,
    username: "Admin",
    password: aws_directory_service_directory.test.password,
    cacheAttributes: {
        cacheStaleTimeoutInSeconds: 400,
    },
    auditDestinationArn: aws_cloudwatch_log_group.test.arn,
});
import pulumi
import pulumi_aws as aws

aws_service_storagegateway_ami_files3_latest = aws.ssm.get_parameter(name="/aws/service/storagegateway/ami/FILE_S3/latest")
test_instance = aws.ec2.Instance("testInstance",
    ami=aws_service_storagegateway_ami_files3_latest.value,
    associate_public_ip_address=True,
    instance_type=aws.ec2/instancetype.InstanceType(data["aws_ec2_instance_type_offering"]["available"]["instance_type"]),
    vpc_security_group_ids=[aws_security_group["test"]["id"]],
    subnet_id=aws_subnet["test"][0]["id"],
    opts=pulumi.ResourceOptions(depends_on=[
            aws_route["test"],
            aws_vpc_dhcp_options_association["test"],
        ]))
test_gateway = aws.storagegateway.Gateway("testGateway",
    gateway_ip_address=test_instance.public_ip,
    gateway_name="test-sgw",
    gateway_timezone="GMT",
    gateway_type="FILE_FSX_SMB",
    smb_active_directory_settings=aws.storagegateway.GatewaySmbActiveDirectorySettingsArgs(
        domain_name=aws_directory_service_directory["test"]["name"],
        password=aws_directory_service_directory["test"]["password"],
        username="Admin",
    ))
test_windows_file_system = aws.fsx.WindowsFileSystem("testWindowsFileSystem",
    active_directory_id=aws_directory_service_directory["test"]["id"],
    security_group_ids=[aws_security_group["test"]["id"]],
    skip_final_backup=True,
    storage_capacity=32,
    subnet_ids=[aws_subnet["test"][0]["id"]],
    throughput_capacity=8)
fsx = aws.storagegateway.FileSystemAssociation("fsx",
    gateway_arn=test_gateway.arn,
    location_arn=test_windows_file_system.arn,
    username="Admin",
    password=aws_directory_service_directory["test"]["password"],
    cache_attributes=aws.storagegateway.FileSystemAssociationCacheAttributesArgs(
        cache_stale_timeout_in_seconds=400,
    ),
    audit_destination_arn=aws_cloudwatch_log_group["test"]["arn"])
using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var awsServiceStoragegatewayAmiFILES3Latest = Output.Create(Aws.Ssm.GetParameter.InvokeAsync(new Aws.Ssm.GetParameterArgs
        {
            Name = "/aws/service/storagegateway/ami/FILE_S3/latest",
        }));
        var testInstance = new Aws.Ec2.Instance("testInstance", new Aws.Ec2.InstanceArgs
        {
            Ami = awsServiceStoragegatewayAmiFILES3Latest.Apply(awsServiceStoragegatewayAmiFILES3Latest => awsServiceStoragegatewayAmiFILES3Latest.Value),
            AssociatePublicIpAddress = true,
            InstanceType = System.Enum.Parse<Aws.Ec2/InstanceType.InstanceType>(data.Aws_ec2_instance_type_offering.Available.Instance_type),
            VpcSecurityGroupIds = 
            {
                aws_security_group.Test.Id,
            },
            SubnetId = aws_subnet.Test[0].Id,
        }, new CustomResourceOptions
        {
            DependsOn = 
            {
                aws_route.Test,
                aws_vpc_dhcp_options_association.Test,
            },
        });
        var testGateway = new Aws.StorageGateway.Gateway("testGateway", new Aws.StorageGateway.GatewayArgs
        {
            GatewayIpAddress = testInstance.PublicIp,
            GatewayName = "test-sgw",
            GatewayTimezone = "GMT",
            GatewayType = "FILE_FSX_SMB",
            SmbActiveDirectorySettings = new Aws.StorageGateway.Inputs.GatewaySmbActiveDirectorySettingsArgs
            {
                DomainName = aws_directory_service_directory.Test.Name,
                Password = aws_directory_service_directory.Test.Password,
                Username = "Admin",
            },
        });
        var testWindowsFileSystem = new Aws.Fsx.WindowsFileSystem("testWindowsFileSystem", new Aws.Fsx.WindowsFileSystemArgs
        {
            ActiveDirectoryId = aws_directory_service_directory.Test.Id,
            SecurityGroupIds = 
            {
                aws_security_group.Test.Id,
            },
            SkipFinalBackup = true,
            StorageCapacity = 32,
            SubnetIds = 
            {
                aws_subnet.Test[0].Id,
            },
            ThroughputCapacity = 8,
        });
        var fsx = new Aws.StorageGateway.FileSystemAssociation("fsx", new Aws.StorageGateway.FileSystemAssociationArgs
        {
            GatewayArn = testGateway.Arn,
            LocationArn = testWindowsFileSystem.Arn,
            Username = "Admin",
            Password = aws_directory_service_directory.Test.Password,
            CacheAttributes = new Aws.StorageGateway.Inputs.FileSystemAssociationCacheAttributesArgs
            {
                CacheStaleTimeoutInSeconds = 400,
            },
            AuditDestinationArn = aws_cloudwatch_log_group.Test.Arn,
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ec2"
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/fsx"
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/ssm"
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/storagegateway"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		awsServiceStoragegatewayAmiFILES3Latest, err := ssm.LookupParameter(ctx, &ssm.LookupParameterArgs{
			Name: "/aws/service/storagegateway/ami/FILE_S3/latest",
		}, nil)
		if err != nil {
			return err
		}
		testInstance, err := ec2.NewInstance(ctx, "testInstance", &ec2.InstanceArgs{
			Ami:                      pulumi.String(awsServiceStoragegatewayAmiFILES3Latest.Value),
			AssociatePublicIpAddress: pulumi.Bool(true),
			InstanceType:             ec2 / InstanceType.InstanceType(data.Aws_ec2_instance_type_offering.Available.Instance_type),
			VpcSecurityGroupIds: pulumi.StringArray{
				pulumi.Any(aws_security_group.Test.Id),
			},
			SubnetId: pulumi.Any(aws_subnet.Test[0].Id),
		}, pulumi.DependsOn([]pulumi.Resource{
			aws_route.Test,
			aws_vpc_dhcp_options_association.Test,
		}))
		if err != nil {
			return err
		}
		testGateway, err := storagegateway.NewGateway(ctx, "testGateway", &storagegateway.GatewayArgs{
			GatewayIpAddress: testInstance.PublicIp,
			GatewayName:      pulumi.String("test-sgw"),
			GatewayTimezone:  pulumi.String("GMT"),
			GatewayType:      pulumi.String("FILE_FSX_SMB"),
			SmbActiveDirectorySettings: &storagegateway.GatewaySmbActiveDirectorySettingsArgs{
				DomainName: pulumi.Any(aws_directory_service_directory.Test.Name),
				Password:   pulumi.Any(aws_directory_service_directory.Test.Password),
				Username:   pulumi.String("Admin"),
			},
		})
		if err != nil {
			return err
		}
		testWindowsFileSystem, err := fsx.NewWindowsFileSystem(ctx, "testWindowsFileSystem", &fsx.WindowsFileSystemArgs{
			ActiveDirectoryId: pulumi.Any(aws_directory_service_directory.Test.Id),
			SecurityGroupIds: pulumi.StringArray{
				pulumi.Any(aws_security_group.Test.Id),
			},
			SkipFinalBackup: pulumi.Bool(true),
			StorageCapacity: pulumi.Int(32),
			SubnetIds: pulumi.StringArray{
				pulumi.Any(aws_subnet.Test[0].Id),
			},
			ThroughputCapacity: pulumi.Int(8),
		})
		if err != nil {
			return err
		}
		_, err = storagegateway.NewFileSystemAssociation(ctx, "fsx", &storagegateway.FileSystemAssociationArgs{
			GatewayArn:  testGateway.Arn,
			LocationArn: testWindowsFileSystem.Arn,
			Username:    pulumi.String("Admin"),
			Password:    pulumi.Any(aws_directory_service_directory.Test.Password),
			CacheAttributes: &storagegateway.FileSystemAssociationCacheAttributesArgs{
				CacheStaleTimeoutInSeconds: pulumi.Int(400),
			},
			AuditDestinationArn: pulumi.Any(aws_cloudwatch_log_group.Test.Arn),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;
import com.pulumi.resources.CustomResourceOptions;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var awsServiceStoragegatewayAmiFILES3Latest = Output.of(SsmFunctions.getParameter(GetParameterArgs.builder()
            .name("/aws/service/storagegateway/ami/FILE_S3/latest")
            .build()));

        var testInstance = new Instance("testInstance", InstanceArgs.builder()        
            .ami(awsServiceStoragegatewayAmiFILES3Latest.apply(getParameterResult -> getParameterResult.value()))
            .associatePublicIpAddress(true)
            .instanceType(data.aws_ec2_instance_type_offering().available().instance_type())
            .vpcSecurityGroupIds(aws_security_group.test().id())
            .subnetId(aws_subnet.test()[0].id())
            .build(), CustomResourceOptions.builder()
                .dependsOn(                
                    aws_route.test(),
                    aws_vpc_dhcp_options_association.test())
                .build());

        var testGateway = new Gateway("testGateway", GatewayArgs.builder()        
            .gatewayIpAddress(testInstance.publicIp())
            .gatewayName("test-sgw")
            .gatewayTimezone("GMT")
            .gatewayType("FILE_FSX_SMB")
            .smbActiveDirectorySettings(GatewaySmbActiveDirectorySettingsArgs.builder()
                .domainName(aws_directory_service_directory.test().name())
                .password(aws_directory_service_directory.test().password())
                .username("Admin")
                .build())
            .build());

        var testWindowsFileSystem = new WindowsFileSystem("testWindowsFileSystem", WindowsFileSystemArgs.builder()        
            .activeDirectoryId(aws_directory_service_directory.test().id())
            .securityGroupIds(aws_security_group.test().id())
            .skipFinalBackup(true)
            .storageCapacity(32)
            .subnetIds(aws_subnet.test()[0].id())
            .throughputCapacity(8)
            .build());

        var fsx = new FileSystemAssociation("fsx", FileSystemAssociationArgs.builder()        
            .gatewayArn(testGateway.arn())
            .locationArn(testWindowsFileSystem.arn())
            .username("Admin")
            .password(aws_directory_service_directory.test().password())
            .cacheAttributes(FileSystemAssociationCacheAttributesArgs.builder()
                .cacheStaleTimeoutInSeconds(400)
                .build())
            .auditDestinationArn(aws_cloudwatch_log_group.test().arn())
            .build());

    }
}
resources:
  testInstance:
    type: aws:ec2:Instance
    properties:
      ami: ${awsServiceStoragegatewayAmiFILES3Latest.value}
      associatePublicIpAddress: true
      instanceType: ${data.aws_ec2_instance_type_offering.available.instance_type}
      vpcSecurityGroupIds:
        - ${aws_security_group.test.id}
      subnetId: ${aws_subnet.test[0].id}
    options:
      dependson:
        - ${aws_route.test}
        - ${aws_vpc_dhcp_options_association.test}
  testGateway:
    type: aws:storagegateway:Gateway
    properties:
      gatewayIpAddress: ${testInstance.publicIp}
      gatewayName: test-sgw
      gatewayTimezone: GMT
      gatewayType: FILE_FSX_SMB
      smbActiveDirectorySettings:
        domainName: ${aws_directory_service_directory.test.name}
        password: ${aws_directory_service_directory.test.password}
        username: Admin
  testWindowsFileSystem:
    type: aws:fsx:WindowsFileSystem
    properties:
      activeDirectoryId: ${aws_directory_service_directory.test.id}
      securityGroupIds:
        - ${aws_security_group.test.id}
      skipFinalBackup: true
      storageCapacity: 32
      subnetIds:
        - ${aws_subnet.test[0].id}
      throughputCapacity: 8
  fsx:
    type: aws:storagegateway:FileSystemAssociation
    properties:
      gatewayArn: ${testGateway.arn}
      locationArn: ${testWindowsFileSystem.arn}
      username: Admin
      password: ${aws_directory_service_directory.test.password}
      cacheAttributes:
        cacheStaleTimeoutInSeconds: 400
      auditDestinationArn: ${aws_cloudwatch_log_group.test.arn}
variables:
  awsServiceStoragegatewayAmiFILES3Latest:
    Fn::Invoke:
      Function: aws:ssm:getParameter
      Arguments:
        name: /aws/service/storagegateway/ami/FILE_S3/latest

Example Usage

using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var example = new Aws.StorageGateway.FileSystemAssociation("example", new Aws.StorageGateway.FileSystemAssociationArgs
        {
            GatewayArn = aws_storagegateway_gateway.Example.Arn,
            LocationArn = aws_fsx_windows_file_system.Example.Arn,
            Username = "Admin",
            Password = "avoid-plaintext-passwords",
            AuditDestinationArn = aws_s3_bucket.Example.Arn,
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/storagegateway"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := storagegateway.NewFileSystemAssociation(ctx, "example", &storagegateway.FileSystemAssociationArgs{
			GatewayArn:          pulumi.Any(aws_storagegateway_gateway.Example.Arn),
			LocationArn:         pulumi.Any(aws_fsx_windows_file_system.Example.Arn),
			Username:            pulumi.String("Admin"),
			Password:            pulumi.String("avoid-plaintext-passwords"),
			AuditDestinationArn: pulumi.Any(aws_s3_bucket.Example.Arn),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var example = new FileSystemAssociation("example", FileSystemAssociationArgs.builder()        
            .gatewayArn(aws_storagegateway_gateway.example().arn())
            .locationArn(aws_fsx_windows_file_system.example().arn())
            .username("Admin")
            .password("avoid-plaintext-passwords")
            .auditDestinationArn(aws_s3_bucket.example().arn())
            .build());

    }
}
import pulumi
import pulumi_aws as aws

example = aws.storagegateway.FileSystemAssociation("example",
    gateway_arn=aws_storagegateway_gateway["example"]["arn"],
    location_arn=aws_fsx_windows_file_system["example"]["arn"],
    username="Admin",
    password="avoid-plaintext-passwords",
    audit_destination_arn=aws_s3_bucket["example"]["arn"])
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.storagegateway.FileSystemAssociation("example", {
    gatewayArn: aws_storagegateway_gateway.example.arn,
    locationArn: aws_fsx_windows_file_system.example.arn,
    username: "Admin",
    password: "avoid-plaintext-passwords",
    auditDestinationArn: aws_s3_bucket.example.arn,
});
resources:
  example:
    type: aws:storagegateway:FileSystemAssociation
    properties:
      gatewayArn: ${aws_storagegateway_gateway.example.arn}
      locationArn: ${aws_fsx_windows_file_system.example.arn}
      username: Admin
      password: avoid-plaintext-passwords
      auditDestinationArn: ${aws_s3_bucket.example.arn}

Create a FileSystemAssociation Resource

new FileSystemAssociation(name: string, args: FileSystemAssociationArgs, opts?: CustomResourceOptions);
@overload
def FileSystemAssociation(resource_name: str,
                          opts: Optional[ResourceOptions] = None,
                          audit_destination_arn: Optional[str] = None,
                          cache_attributes: Optional[FileSystemAssociationCacheAttributesArgs] = None,
                          gateway_arn: Optional[str] = None,
                          location_arn: Optional[str] = None,
                          password: Optional[str] = None,
                          tags: Optional[Mapping[str, str]] = None,
                          username: Optional[str] = None)
@overload
def FileSystemAssociation(resource_name: str,
                          args: FileSystemAssociationArgs,
                          opts: Optional[ResourceOptions] = None)
func NewFileSystemAssociation(ctx *Context, name string, args FileSystemAssociationArgs, opts ...ResourceOption) (*FileSystemAssociation, error)
public FileSystemAssociation(string name, FileSystemAssociationArgs args, CustomResourceOptions? opts = null)
public FileSystemAssociation(String name, FileSystemAssociationArgs args)
public FileSystemAssociation(String name, FileSystemAssociationArgs args, CustomResourceOptions options)
type: aws:storagegateway:FileSystemAssociation
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args FileSystemAssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args FileSystemAssociationArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args FileSystemAssociationArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args FileSystemAssociationArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args FileSystemAssociationArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

FileSystemAssociation Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The FileSystemAssociation resource accepts the following input properties:

GatewayArn string

The Amazon Resource Name (ARN) of the gateway.

LocationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

Password string

The password of the user credential.

Username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

AuditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

CacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

Tags Dictionary<string, string>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

GatewayArn string

The Amazon Resource Name (ARN) of the gateway.

LocationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

Password string

The password of the user credential.

Username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

AuditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

CacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

Tags map[string]string

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

gatewayArn String

The Amazon Resource Name (ARN) of the gateway.

locationArn String

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password String

The password of the user credential.

username String

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

auditDestinationArn String

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

tags Map<String,String>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

gatewayArn string

The Amazon Resource Name (ARN) of the gateway.

locationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password string

The password of the user credential.

username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

auditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

tags {[key: string]: string}

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

gateway_arn str

The Amazon Resource Name (ARN) of the gateway.

location_arn str

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password str

The password of the user credential.

username str

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

audit_destination_arn str

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cache_attributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

tags Mapping[str, str]

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

gatewayArn String

The Amazon Resource Name (ARN) of the gateway.

locationArn String

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password String

The password of the user credential.

username String

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

auditDestinationArn String

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes Property Map

Refresh cache information. see Cache Attributes for more details.

tags Map<String>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Outputs

All input properties are implicitly available as output properties. Additionally, the FileSystemAssociation resource produces the following output properties:

Arn string

Amazon Resource Name (ARN) of the newly created file system association.

Id string

The provider-assigned unique ID for this managed resource.

TagsAll Dictionary<string, string>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Arn string

Amazon Resource Name (ARN) of the newly created file system association.

Id string

The provider-assigned unique ID for this managed resource.

TagsAll map[string]string

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

arn String

Amazon Resource Name (ARN) of the newly created file system association.

id String

The provider-assigned unique ID for this managed resource.

tagsAll Map<String,String>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

arn string

Amazon Resource Name (ARN) of the newly created file system association.

id string

The provider-assigned unique ID for this managed resource.

tagsAll {[key: string]: string}

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

arn str

Amazon Resource Name (ARN) of the newly created file system association.

id str

The provider-assigned unique ID for this managed resource.

tags_all Mapping[str, str]

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

arn String

Amazon Resource Name (ARN) of the newly created file system association.

id String

The provider-assigned unique ID for this managed resource.

tagsAll Map<String>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Look up an Existing FileSystemAssociation Resource

Get an existing FileSystemAssociation resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: FileSystemAssociationState, opts?: CustomResourceOptions): FileSystemAssociation
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        arn: Optional[str] = None,
        audit_destination_arn: Optional[str] = None,
        cache_attributes: Optional[FileSystemAssociationCacheAttributesArgs] = None,
        gateway_arn: Optional[str] = None,
        location_arn: Optional[str] = None,
        password: Optional[str] = None,
        tags: Optional[Mapping[str, str]] = None,
        tags_all: Optional[Mapping[str, str]] = None,
        username: Optional[str] = None) -> FileSystemAssociation
func GetFileSystemAssociation(ctx *Context, name string, id IDInput, state *FileSystemAssociationState, opts ...ResourceOption) (*FileSystemAssociation, error)
public static FileSystemAssociation Get(string name, Input<string> id, FileSystemAssociationState? state, CustomResourceOptions? opts = null)
public static FileSystemAssociation get(String name, Output<String> id, FileSystemAssociationState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
Arn string

Amazon Resource Name (ARN) of the newly created file system association.

AuditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

CacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

GatewayArn string

The Amazon Resource Name (ARN) of the gateway.

LocationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

Password string

The password of the user credential.

Tags Dictionary<string, string>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

TagsAll Dictionary<string, string>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

Arn string

Amazon Resource Name (ARN) of the newly created file system association.

AuditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

CacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

GatewayArn string

The Amazon Resource Name (ARN) of the gateway.

LocationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

Password string

The password of the user credential.

Tags map[string]string

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

TagsAll map[string]string

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

arn String

Amazon Resource Name (ARN) of the newly created file system association.

auditDestinationArn String

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

gatewayArn String

The Amazon Resource Name (ARN) of the gateway.

locationArn String

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password String

The password of the user credential.

tags Map<String,String>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

tagsAll Map<String,String>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

username String

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

arn string

Amazon Resource Name (ARN) of the newly created file system association.

auditDestinationArn string

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

gatewayArn string

The Amazon Resource Name (ARN) of the gateway.

locationArn string

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password string

The password of the user credential.

tags {[key: string]: string}

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

tagsAll {[key: string]: string}

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

username string

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

arn str

Amazon Resource Name (ARN) of the newly created file system association.

audit_destination_arn str

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cache_attributes FileSystemAssociationCacheAttributesArgs

Refresh cache information. see Cache Attributes for more details.

gateway_arn str

The Amazon Resource Name (ARN) of the gateway.

location_arn str

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password str

The password of the user credential.

tags Mapping[str, str]

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

tags_all Mapping[str, str]

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

username str

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

arn String

Amazon Resource Name (ARN) of the newly created file system association.

auditDestinationArn String

The Amazon Resource Name (ARN) of the storage used for the audit logs.

cacheAttributes Property Map

Refresh cache information. see Cache Attributes for more details.

gatewayArn String

The Amazon Resource Name (ARN) of the gateway.

locationArn String

The Amazon Resource Name (ARN) of the Amazon FSx file system to associate with the FSx File Gateway.

password String

The password of the user credential.

tags Map<String>

Key-value map of resource tags. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

tagsAll Map<String>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

username String

The user name of the user credential that has permission to access the root share of the Amazon FSx file system. The user account must belong to the Amazon FSx delegated admin user group.

Supporting Types

FileSystemAssociationCacheAttributes

CacheStaleTimeoutInSeconds int

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

CacheStaleTimeoutInSeconds int

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

cacheStaleTimeoutInSeconds Integer

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

cacheStaleTimeoutInSeconds number

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

cache_stale_timeout_in_seconds int

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

cacheStaleTimeoutInSeconds Number

Refreshes a file share's cache by using Time To Live (TTL). TTL is the length of time since the last refresh after which access to the directory would cause the file gateway to first refresh that directory's contents from the Amazon S3 bucket. Valid Values: 0 or 300 to 2592000 seconds (5 minutes to 30 days). Defaults to 0

Import

aws_storagegateway_file_system_association can be imported by using the FSx file system association Amazon Resource Name (ARN), e.g.,

 $ pulumi import aws:storagegateway/fileSystemAssociation:FileSystemAssociation example arn:aws:storagegateway:us-east-1:123456789012:fs-association/fsa-0DA347732FDB40125

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.