import * as core from "@terrascript/core"; export interface PosixProfileArgs extends core.SchemaArgs { gid: number | core.NumberOut; secondaryGids?: core.Array | core.ArrayOut; uid: number | core.NumberOut; } export class PosixProfile extends core.Schema { @core.attr(Number) public gid!: number | core.NumberOut; @core.attr(Number, { kind: "array" }) public secondaryGids?: core.Array | core.ArrayOut; @core.attr(Number) public uid!: number | core.NumberOut; } export interface HomeDirectoryMappingsArgs extends core.SchemaArgs { entry: string | core.StringOut; target: string | core.StringOut; } export class HomeDirectoryMappings extends core.Schema { @core.attr(String) public entry!: string | core.StringOut; @core.attr(String) public target!: string | core.StringOut; } export interface UserArgs extends core.ResourceArgs { /** * (Optional) The landing directory (folder) for a user when they log in to the server using their SFTP * client. It should begin with a `/`. The first item in the path is the name of the home bucket (ac * cessible as `${Transfer:HomeBucket}` in the policy) and the rest is the home directory (accessible a * s `${Transfer:HomeDirectory}` in the policy). For example, `/example-bucket-1234/username` would set * the home bucket to `example-bucket-1234` and the home directory to `username`. */ homeDirectory?: string | core.StringOut; /** * (Optional) Logical directory mappings that specify what S3 paths and keys should be visible to your * user and how you want to make them visible. See [Home Directory Mappings](#home-directory-mappings) * below. */ homeDirectoryMappings?: | core.Array | core.ArrayOut; /** * (Optional) The type of landing directory (folder) you mapped for your users' home directory. Valid v * alues are `PATH` and `LOGICAL`. */ homeDirectoryType?: string | core.StringOut; /** * (Optional) An IAM JSON policy document that scopes down user access to portions of their Amazon S3 b * ucket. IAM variables you can use inside this policy include `${Transfer:UserName}`, `${Transfer:Home * Directory}`, and `${Transfer:HomeBucket}`. Since the IAM variable syntax matches Terraform's interpo * lation syntax, they must be escaped inside Terraform configuration strings (`$${Transfer:UserName}`) * . These are evaluated on-the-fly when navigating the bucket. */ policy?: string | core.StringOut; /** * (Optional) Specifies the full POSIX identity, including user ID (Uid), group ID (Gid), and any secon * dary groups IDs (SecondaryGids), that controls your users' access to your Amazon EFS file systems. S * ee [Posix Profile](#posix-profile) below. */ posixProfile?: PosixProfile; /** * (Required) Amazon Resource Name (ARN) of an IAM role that allows the service to controls your user’s * access to your Amazon S3 bucket. */ role: string | core.StringOut; /** * (Required) The Server ID of the Transfer Server (e.g., `s-12345678`) */ serverId: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; /** * (Required) The name used for log in to your SFTP server. */ userName: string | core.StringOut; } export class User extends core.Resource { /** * Amazon Resource Name (ARN) of Transfer User */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Optional) The landing directory (folder) for a user when they log in to the server using their SFTP * client. It should begin with a `/`. The first item in the path is the name of the home bucket (ac * cessible as `${Transfer:HomeBucket}` in the policy) and the rest is the home directory (accessible a * s `${Transfer:HomeDirectory}` in the policy). For example, `/example-bucket-1234/username` would set * the home bucket to `example-bucket-1234` and the home directory to `username`. */ @core.attr(String) public homeDirectory?: string | core.StringOut; /** * (Optional) Logical directory mappings that specify what S3 paths and keys should be visible to your * user and how you want to make them visible. See [Home Directory Mappings](#home-directory-mappings) * below. */ @core.attr(HomeDirectoryMappings, { kind: "array" }) public homeDirectoryMappings?: | core.Array | core.ArrayOut; /** * (Optional) The type of landing directory (folder) you mapped for your users' home directory. Valid v * alues are `PATH` and `LOGICAL`. */ @core.attr(String) public homeDirectoryType?: string | core.StringOut; @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Optional) An IAM JSON policy document that scopes down user access to portions of their Amazon S3 b * ucket. IAM variables you can use inside this policy include `${Transfer:UserName}`, `${Transfer:Home * Directory}`, and `${Transfer:HomeBucket}`. Since the IAM variable syntax matches Terraform's interpo * lation syntax, they must be escaped inside Terraform configuration strings (`$${Transfer:UserName}`) * . These are evaluated on-the-fly when navigating the bucket. */ @core.attr(String) public policy?: string | core.StringOut; /** * (Optional) Specifies the full POSIX identity, including user ID (Uid), group ID (Gid), and any secon * dary groups IDs (SecondaryGids), that controls your users' access to your Amazon EFS file systems. S * ee [Posix Profile](#posix-profile) below. */ @core.attr(PosixProfile) public posixProfile?: PosixProfile; /** * (Required) Amazon Resource Name (ARN) of an IAM role that allows the service to controls your user’s * access to your Amazon S3 bucket. */ @core.attr(String) public role!: string | core.StringOut; /** * (Required) The Server ID of the Transfer Server (e.g., `s-12345678`) */ @core.attr(String) public serverId!: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; /** * (Required) The name used for log in to your SFTP server. */ @core.attr(String) public userName!: string | core.StringOut; constructor(name: string, args?: UserArgs) { super(name, "aws_transfer_user", args); } public override getNamespace(): string { return "aws_transfer"; } }