@pulumi/aws
Version:
A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.
447 lines (446 loc) • 22.8 kB
TypeScript
import * as pulumi from "@pulumi/pulumi";
import * as inputs from "../types/input";
import * as outputs from "../types/output";
/**
* Manages a FSx Windows File System. See the [FSx Windows Guide](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/what-is.html) for more information.
*
* > **NOTE:** Either the `activeDirectoryId` argument or `selfManagedActiveDirectory` configuration block must be specified.
*
* ## Example Usage
*
* ### Using AWS Directory Service
*
* Additional information for using AWS Directory Service with Windows File Systems can be found in the [FSx Windows Guide](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/fsx-aws-managed-ad.html).
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = new aws.fsx.WindowsFileSystem("example", {
* activeDirectoryId: exampleAwsDirectoryServiceDirectory.id,
* kmsKeyId: exampleAwsKmsKey.arn,
* storageCapacity: 32,
* subnetIds: [exampleAwsSubnet.id],
* throughputCapacity: 32,
* });
* ```
*
* ### Using a Self-Managed Microsoft Active Directory
*
* Additional information for using AWS Directory Service with Windows File Systems can be found in the [FSx Windows Guide](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/self-managed-AD.html).
*
* ```typescript
* import * as pulumi from "@pulumi/pulumi";
* import * as aws from "@pulumi/aws";
*
* const example = new aws.fsx.WindowsFileSystem("example", {
* kmsKeyId: exampleAwsKmsKey.arn,
* storageCapacity: 32,
* subnetIds: [exampleAwsSubnet.id],
* throughputCapacity: 32,
* selfManagedActiveDirectory: {
* dnsIps: [
* "10.0.0.111",
* "10.0.0.222",
* ],
* domainName: "corp.example.com",
* password: "avoid-plaintext-passwords",
* username: "Admin",
* },
* });
* ```
*
* ## Import
*
* Using `pulumi import`, import FSx File Systems using the `id`. For example:
*
* ```sh
* $ pulumi import aws:fsx/windowsFileSystem:WindowsFileSystem example fs-543ab12b1ca672f33
* ```
* Certain resource arguments, like `security_group_ids` and the `self_managed_active_directory` configuation block `password`, do not have a FSx API method for reading the information after creation. If these arguments are set in the Pulumi program on an imported resource, Pulumi will always show a difference. To workaround this behavior, either omit the argument from the Pulumi program or use `ignore_changes` to hide the difference. For example:
*/
export declare class WindowsFileSystem extends pulumi.CustomResource {
/**
* Get an existing WindowsFileSystem resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param state Any extra arguments used during the lookup.
* @param opts Optional settings to control the behavior of the CustomResource.
*/
static get(name: string, id: pulumi.Input<pulumi.ID>, state?: WindowsFileSystemState, opts?: pulumi.CustomResourceOptions): WindowsFileSystem;
/**
* Returns true if the given object is an instance of WindowsFileSystem. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj: any): obj is WindowsFileSystem;
/**
* The ID for an existing Microsoft Active Directory instance that the file system should join when it's created. Cannot be specified with `selfManagedActiveDirectory`.
*/
readonly activeDirectoryId: pulumi.Output<string | undefined>;
/**
* An array DNS alias names that you want to associate with the Amazon FSx file system. For more information, see [Working with DNS Aliases](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/managing-dns-aliases.html)
*/
readonly aliases: pulumi.Output<string[] | undefined>;
/**
* Amazon Resource Name of the file system.
*/
readonly arn: pulumi.Output<string>;
/**
* The configuration that Amazon FSx for Windows File Server uses to audit and log user accesses of files, folders, and file shares on the Amazon FSx for Windows File Server file system. See `auditLogConfiguration` Block for details.
*/
readonly auditLogConfiguration: pulumi.Output<outputs.fsx.WindowsFileSystemAuditLogConfiguration>;
/**
* The number of days to retain automatic backups. Minimum of `0` and maximum of `90`. Defaults to `7`. Set to `0` to disable.
*/
readonly automaticBackupRetentionDays: pulumi.Output<number | undefined>;
/**
* The ID of the source backup to create the filesystem from.
*/
readonly backupId: pulumi.Output<string | undefined>;
/**
* A boolean flag indicating whether tags on the file system should be copied to backups. Defaults to `false`.
*/
readonly copyTagsToBackups: pulumi.Output<boolean | undefined>;
/**
* The preferred time (in `HH:MM` format) to take daily automatic backups, in the UTC time zone.
*/
readonly dailyAutomaticBackupStartTime: pulumi.Output<string>;
/**
* Specifies the file system deployment type, valid values are `MULTI_AZ_1`, `SINGLE_AZ_1` and `SINGLE_AZ_2`. Default value is `SINGLE_AZ_1`.
*/
readonly deploymentType: pulumi.Output<string | undefined>;
/**
* The SSD IOPS configuration for the Amazon FSx for Windows File Server file system. See `diskIopsConfiguration` Block for details.
*/
readonly diskIopsConfiguration: pulumi.Output<outputs.fsx.WindowsFileSystemDiskIopsConfiguration>;
/**
* DNS name for the file system, e.g., `fs-12345678.corp.example.com` (domain name matching the Active Directory domain name)
*/
readonly dnsName: pulumi.Output<string>;
/**
* A map of tags to apply to the file system's final backup.
*/
readonly finalBackupTags: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* ARN for the KMS Key to encrypt the file system at rest. Defaults to an AWS managed KMS Key.
*/
readonly kmsKeyId: pulumi.Output<string>;
/**
* Set of Elastic Network Interface identifiers from which the file system is accessible.
*/
readonly networkInterfaceIds: pulumi.Output<string[]>;
/**
* AWS account identifier that created the file system.
*/
readonly ownerId: pulumi.Output<string>;
/**
* The IP address of the primary, or preferred, file server.
*/
readonly preferredFileServerIp: pulumi.Output<string>;
/**
* Specifies the subnet in which you want the preferred file server to be located. Required for when deployment type is `MULTI_AZ_1`.
*/
readonly preferredSubnetId: pulumi.Output<string>;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
readonly region: pulumi.Output<string>;
/**
* For `MULTI_AZ_1` deployment types, use this endpoint when performing administrative tasks on the file system using Amazon FSx Remote PowerShell. For `SINGLE_AZ_1` deployment types, this is the DNS name of the file system.
*/
readonly remoteAdministrationEndpoint: pulumi.Output<string>;
/**
* A list of IDs for the security groups that apply to the specified network interfaces created for file system access. These security groups will apply to all network interfaces.
*/
readonly securityGroupIds: pulumi.Output<string[] | undefined>;
/**
* Configuration block that Amazon FSx uses to join the Windows File Server instance to your self-managed (including on-premises) Microsoft Active Directory (AD) directory. Cannot be specified with `activeDirectoryId`. See `selfManagedActiveDirectory` Block for details.
*/
readonly selfManagedActiveDirectory: pulumi.Output<outputs.fsx.WindowsFileSystemSelfManagedActiveDirectory | undefined>;
/**
* When enabled, will skip the default final backup taken when the file system is deleted. This configuration must be applied separately before attempting to delete the resource to have the desired behavior. Defaults to `false`.
*/
readonly skipFinalBackup: pulumi.Output<boolean | undefined>;
/**
* Storage capacity (GiB) of the file system. Minimum of 32 and maximum of 65536. If the storage type is set to `HDD` the minimum value is 2000. Required when not creating filesystem for a backup.
*/
readonly storageCapacity: pulumi.Output<number>;
/**
* Specifies the storage type, Valid values are `SSD` and `HDD`. `HDD` is supported on `SINGLE_AZ_2` and `MULTI_AZ_1` Windows file system deployment types. Default value is `SSD`.
*/
readonly storageType: pulumi.Output<string | undefined>;
/**
* A list of IDs for the subnets that the file system will be accessible from. To specify more than a single subnet set `deploymentType` to `MULTI_AZ_1`.
*/
readonly subnetIds: pulumi.Output<string[]>;
/**
* A map of tags to assign to the file system. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
readonly tags: pulumi.Output<{
[key: string]: string;
} | undefined>;
/**
* A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
*/
readonly tagsAll: pulumi.Output<{
[key: string]: string;
}>;
/**
* Throughput (megabytes per second) of the file system. For valid values, refer to the [AWS documentation](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/performance.html).
*
* The following arguments are optional:
*/
readonly throughputCapacity: pulumi.Output<number>;
/**
* Identifier of the Virtual Private Cloud for the file system.
*/
readonly vpcId: pulumi.Output<string>;
/**
* The preferred start time (in `d:HH:MM` format) to perform weekly maintenance, in the UTC time zone.
*/
readonly weeklyMaintenanceStartTime: pulumi.Output<string>;
/**
* Create a WindowsFileSystem resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name: string, args: WindowsFileSystemArgs, opts?: pulumi.CustomResourceOptions);
}
/**
* Input properties used for looking up and filtering WindowsFileSystem resources.
*/
export interface WindowsFileSystemState {
/**
* The ID for an existing Microsoft Active Directory instance that the file system should join when it's created. Cannot be specified with `selfManagedActiveDirectory`.
*/
activeDirectoryId?: pulumi.Input<string>;
/**
* An array DNS alias names that you want to associate with the Amazon FSx file system. For more information, see [Working with DNS Aliases](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/managing-dns-aliases.html)
*/
aliases?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Amazon Resource Name of the file system.
*/
arn?: pulumi.Input<string>;
/**
* The configuration that Amazon FSx for Windows File Server uses to audit and log user accesses of files, folders, and file shares on the Amazon FSx for Windows File Server file system. See `auditLogConfiguration` Block for details.
*/
auditLogConfiguration?: pulumi.Input<inputs.fsx.WindowsFileSystemAuditLogConfiguration>;
/**
* The number of days to retain automatic backups. Minimum of `0` and maximum of `90`. Defaults to `7`. Set to `0` to disable.
*/
automaticBackupRetentionDays?: pulumi.Input<number>;
/**
* The ID of the source backup to create the filesystem from.
*/
backupId?: pulumi.Input<string>;
/**
* A boolean flag indicating whether tags on the file system should be copied to backups. Defaults to `false`.
*/
copyTagsToBackups?: pulumi.Input<boolean>;
/**
* The preferred time (in `HH:MM` format) to take daily automatic backups, in the UTC time zone.
*/
dailyAutomaticBackupStartTime?: pulumi.Input<string>;
/**
* Specifies the file system deployment type, valid values are `MULTI_AZ_1`, `SINGLE_AZ_1` and `SINGLE_AZ_2`. Default value is `SINGLE_AZ_1`.
*/
deploymentType?: pulumi.Input<string>;
/**
* The SSD IOPS configuration for the Amazon FSx for Windows File Server file system. See `diskIopsConfiguration` Block for details.
*/
diskIopsConfiguration?: pulumi.Input<inputs.fsx.WindowsFileSystemDiskIopsConfiguration>;
/**
* DNS name for the file system, e.g., `fs-12345678.corp.example.com` (domain name matching the Active Directory domain name)
*/
dnsName?: pulumi.Input<string>;
/**
* A map of tags to apply to the file system's final backup.
*/
finalBackupTags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* ARN for the KMS Key to encrypt the file system at rest. Defaults to an AWS managed KMS Key.
*/
kmsKeyId?: pulumi.Input<string>;
/**
* Set of Elastic Network Interface identifiers from which the file system is accessible.
*/
networkInterfaceIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* AWS account identifier that created the file system.
*/
ownerId?: pulumi.Input<string>;
/**
* The IP address of the primary, or preferred, file server.
*/
preferredFileServerIp?: pulumi.Input<string>;
/**
* Specifies the subnet in which you want the preferred file server to be located. Required for when deployment type is `MULTI_AZ_1`.
*/
preferredSubnetId?: pulumi.Input<string>;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: pulumi.Input<string>;
/**
* For `MULTI_AZ_1` deployment types, use this endpoint when performing administrative tasks on the file system using Amazon FSx Remote PowerShell. For `SINGLE_AZ_1` deployment types, this is the DNS name of the file system.
*/
remoteAdministrationEndpoint?: pulumi.Input<string>;
/**
* A list of IDs for the security groups that apply to the specified network interfaces created for file system access. These security groups will apply to all network interfaces.
*/
securityGroupIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Configuration block that Amazon FSx uses to join the Windows File Server instance to your self-managed (including on-premises) Microsoft Active Directory (AD) directory. Cannot be specified with `activeDirectoryId`. See `selfManagedActiveDirectory` Block for details.
*/
selfManagedActiveDirectory?: pulumi.Input<inputs.fsx.WindowsFileSystemSelfManagedActiveDirectory>;
/**
* When enabled, will skip the default final backup taken when the file system is deleted. This configuration must be applied separately before attempting to delete the resource to have the desired behavior. Defaults to `false`.
*/
skipFinalBackup?: pulumi.Input<boolean>;
/**
* Storage capacity (GiB) of the file system. Minimum of 32 and maximum of 65536. If the storage type is set to `HDD` the minimum value is 2000. Required when not creating filesystem for a backup.
*/
storageCapacity?: pulumi.Input<number>;
/**
* Specifies the storage type, Valid values are `SSD` and `HDD`. `HDD` is supported on `SINGLE_AZ_2` and `MULTI_AZ_1` Windows file system deployment types. Default value is `SSD`.
*/
storageType?: pulumi.Input<string>;
/**
* A list of IDs for the subnets that the file system will be accessible from. To specify more than a single subnet set `deploymentType` to `MULTI_AZ_1`.
*/
subnetIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* A map of tags to assign to the file system. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
tags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
*/
tagsAll?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Throughput (megabytes per second) of the file system. For valid values, refer to the [AWS documentation](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/performance.html).
*
* The following arguments are optional:
*/
throughputCapacity?: pulumi.Input<number>;
/**
* Identifier of the Virtual Private Cloud for the file system.
*/
vpcId?: pulumi.Input<string>;
/**
* The preferred start time (in `d:HH:MM` format) to perform weekly maintenance, in the UTC time zone.
*/
weeklyMaintenanceStartTime?: pulumi.Input<string>;
}
/**
* The set of arguments for constructing a WindowsFileSystem resource.
*/
export interface WindowsFileSystemArgs {
/**
* The ID for an existing Microsoft Active Directory instance that the file system should join when it's created. Cannot be specified with `selfManagedActiveDirectory`.
*/
activeDirectoryId?: pulumi.Input<string>;
/**
* An array DNS alias names that you want to associate with the Amazon FSx file system. For more information, see [Working with DNS Aliases](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/managing-dns-aliases.html)
*/
aliases?: pulumi.Input<pulumi.Input<string>[]>;
/**
* The configuration that Amazon FSx for Windows File Server uses to audit and log user accesses of files, folders, and file shares on the Amazon FSx for Windows File Server file system. See `auditLogConfiguration` Block for details.
*/
auditLogConfiguration?: pulumi.Input<inputs.fsx.WindowsFileSystemAuditLogConfiguration>;
/**
* The number of days to retain automatic backups. Minimum of `0` and maximum of `90`. Defaults to `7`. Set to `0` to disable.
*/
automaticBackupRetentionDays?: pulumi.Input<number>;
/**
* The ID of the source backup to create the filesystem from.
*/
backupId?: pulumi.Input<string>;
/**
* A boolean flag indicating whether tags on the file system should be copied to backups. Defaults to `false`.
*/
copyTagsToBackups?: pulumi.Input<boolean>;
/**
* The preferred time (in `HH:MM` format) to take daily automatic backups, in the UTC time zone.
*/
dailyAutomaticBackupStartTime?: pulumi.Input<string>;
/**
* Specifies the file system deployment type, valid values are `MULTI_AZ_1`, `SINGLE_AZ_1` and `SINGLE_AZ_2`. Default value is `SINGLE_AZ_1`.
*/
deploymentType?: pulumi.Input<string>;
/**
* The SSD IOPS configuration for the Amazon FSx for Windows File Server file system. See `diskIopsConfiguration` Block for details.
*/
diskIopsConfiguration?: pulumi.Input<inputs.fsx.WindowsFileSystemDiskIopsConfiguration>;
/**
* A map of tags to apply to the file system's final backup.
*/
finalBackupTags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* ARN for the KMS Key to encrypt the file system at rest. Defaults to an AWS managed KMS Key.
*/
kmsKeyId?: pulumi.Input<string>;
/**
* Specifies the subnet in which you want the preferred file server to be located. Required for when deployment type is `MULTI_AZ_1`.
*/
preferredSubnetId?: pulumi.Input<string>;
/**
* Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
*/
region?: pulumi.Input<string>;
/**
* A list of IDs for the security groups that apply to the specified network interfaces created for file system access. These security groups will apply to all network interfaces.
*/
securityGroupIds?: pulumi.Input<pulumi.Input<string>[]>;
/**
* Configuration block that Amazon FSx uses to join the Windows File Server instance to your self-managed (including on-premises) Microsoft Active Directory (AD) directory. Cannot be specified with `activeDirectoryId`. See `selfManagedActiveDirectory` Block for details.
*/
selfManagedActiveDirectory?: pulumi.Input<inputs.fsx.WindowsFileSystemSelfManagedActiveDirectory>;
/**
* When enabled, will skip the default final backup taken when the file system is deleted. This configuration must be applied separately before attempting to delete the resource to have the desired behavior. Defaults to `false`.
*/
skipFinalBackup?: pulumi.Input<boolean>;
/**
* Storage capacity (GiB) of the file system. Minimum of 32 and maximum of 65536. If the storage type is set to `HDD` the minimum value is 2000. Required when not creating filesystem for a backup.
*/
storageCapacity?: pulumi.Input<number>;
/**
* Specifies the storage type, Valid values are `SSD` and `HDD`. `HDD` is supported on `SINGLE_AZ_2` and `MULTI_AZ_1` Windows file system deployment types. Default value is `SSD`.
*/
storageType?: pulumi.Input<string>;
/**
* A list of IDs for the subnets that the file system will be accessible from. To specify more than a single subnet set `deploymentType` to `MULTI_AZ_1`.
*/
subnetIds: pulumi.Input<pulumi.Input<string>[]>;
/**
* A map of tags to assign to the file system. .If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
*/
tags?: pulumi.Input<{
[key: string]: pulumi.Input<string>;
}>;
/**
* Throughput (megabytes per second) of the file system. For valid values, refer to the [AWS documentation](https://docs.aws.amazon.com/fsx/latest/WindowsGuide/performance.html).
*
* The following arguments are optional:
*/
throughputCapacity: pulumi.Input<number>;
/**
* The preferred start time (in `d:HH:MM` format) to perform weekly maintenance, in the UTC time zone.
*/
weeklyMaintenanceStartTime?: pulumi.Input<string>;
}