Resource: aws_transfer_access

Provides a AWS Transfer Access resource.

Example Usage

Basic S3

resource "aws_transfer_access" "example" {
  external_id    = "S-1-1-12-1234567890-123456789-1234567890-1234"
  server_id      = aws_transfer_server.example.id
  role           = aws_iam_role.example.arn
  home_directory = "/${aws_s3_bucket.example.id}/"
}

Basic EFS

resource "aws_transfer_access" "test" {
  external_id    = "S-1-1-12-1234567890-123456789-1234567890-1234"
  server_id      = aws_transfer_server.test.id
  role           = aws_iam_role.test.arn
  home_directory = "/${aws_efs_file_system.test.id}/"
  posix_profile {
    gid = 1000
    uid = 1000
  }
}

Argument Reference

This resource supports the following arguments:

Home Directory Mappings

Posix Profile

Attribute Reference

This resource exports the following attributes in addition to the arguments above:

Import

In Terraform v1.5.0 and later, use an import block to import Transfer Accesses using the server_id and external_id. For example:

import {
  to = aws_transfer_access.example
  id = "s-12345678/S-1-1-12-1234567890-123456789-1234567890-1234"
}

Using terraform import, import Transfer Accesses using the server_id and external_id. For example:

% terraform import aws_transfer_access.example s-12345678/S-1-1-12-1234567890-123456789-1234567890-1234