Alibaba Cloud

Pulumi Official
Package maintained by Pulumi
v3.19.0 published on Friday, Mar 18, 2022 by Pulumi

FileSystem

Provides a Nas File System resource.

After activating NAS, you can create a file system and purchase a storage package for it in the NAS console. The NAS console also enables you to view the file system details and remove unnecessary file systems.

For information about NAS file system and how to use it, see Manage file systems

NOTE: Available in v1.33.0+.

Example Usage

using Pulumi;
using AliCloud = Pulumi.AliCloud;

class MyStack : Stack
{
    public MyStack()
    {
        var foo = new AliCloud.Nas.FileSystem("foo", new AliCloud.Nas.FileSystemArgs
        {
            Description = "tf-testAccNasConfig",
            EncryptType = 1,
            ProtocolType = "NFS",
            StorageType = "Performance",
        });
    }

}
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/nas"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := nas.NewFileSystem(ctx, "foo", &nas.FileSystemArgs{
			Description:  pulumi.String("tf-testAccNasConfig"),
			EncryptType:  pulumi.Int(1),
			ProtocolType: pulumi.String("NFS"),
			StorageType:  pulumi.String("Performance"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}

Coming soon!

import pulumi
import pulumi_alicloud as alicloud

foo = alicloud.nas.FileSystem("foo",
    description="tf-testAccNasConfig",
    encrypt_type=1,
    protocol_type="NFS",
    storage_type="Performance")
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";

const foo = new alicloud.nas.FileSystem("foo", {
    description: "tf-testAccNasConfig",
    encryptType: 1,
    protocolType: "NFS",
    storageType: "Performance",
});

Coming soon!

Create a FileSystem Resource

new FileSystem(name: string, args: FileSystemArgs, opts?: CustomResourceOptions);
@overload
def FileSystem(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               capacity: Optional[int] = None,
               description: Optional[str] = None,
               encrypt_type: Optional[int] = None,
               file_system_type: Optional[str] = None,
               kms_key_id: Optional[str] = None,
               protocol_type: Optional[str] = None,
               storage_type: Optional[str] = None,
               tags: Optional[Mapping[str, Any]] = None,
               vpc_id: Optional[str] = None,
               vswitch_id: Optional[str] = None,
               zone_id: Optional[str] = None)
@overload
def FileSystem(resource_name: str,
               args: FileSystemArgs,
               opts: Optional[ResourceOptions] = None)
func NewFileSystem(ctx *Context, name string, args FileSystemArgs, opts ...ResourceOption) (*FileSystem, error)
public FileSystem(string name, FileSystemArgs args, CustomResourceOptions? opts = null)
public FileSystem(String name, FileSystemArgs args)
public FileSystem(String name, FileSystemArgs args, CustomResourceOptions options)
type: alicloud:nas:FileSystem
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args FileSystemArgs
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 FileSystemArgs
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 FileSystemArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args FileSystemArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args FileSystemArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

FileSystem 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 FileSystem resource accepts the following input properties:

ProtocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

StorageType string

The storage type of the file System.

  • Valid values:
Capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

Description string

The File System description.

EncryptType int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
FileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

KmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

Tags Dictionary<string, object>

A mapping of tags to assign to the resource.

VpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

VswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

ZoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

ProtocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

StorageType string

The storage type of the file System.

  • Valid values:
Capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

Description string

The File System description.

EncryptType int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
FileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

KmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

Tags map[string]interface{}

A mapping of tags to assign to the resource.

VpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

VswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

ZoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

protocolType String

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType String

The storage type of the file System.

  • Valid values:
capacity Integer

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description String

The File System description.

encryptType Integer

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType String

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId String

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

tags Map

A mapping of tags to assign to the resource.

vpcId String

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId String

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId String

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

protocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType string

The storage type of the file System.

  • Valid values:
capacity number

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description string

The File System description.

encryptType number

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

tags {[key: string]: any}

A mapping of tags to assign to the resource.

vpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

protocol_type str

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storage_type str

The storage type of the file System.

  • Valid values:
capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description str

The File System description.

encrypt_type int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
file_system_type str

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kms_key_id str

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

tags Mapping[str, Any]

A mapping of tags to assign to the resource.

vpc_id str

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitch_id str

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zone_id str

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

protocolType String

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType String

The storage type of the file System.

  • Valid values:
capacity Number

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description String

The File System description.

encryptType Number

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType String

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId String

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

tags Map

A mapping of tags to assign to the resource.

vpcId String

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId String

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId String

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

Outputs

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

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up an Existing FileSystem Resource

Get an existing FileSystem 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?: FileSystemState, opts?: CustomResourceOptions): FileSystem
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        capacity: Optional[int] = None,
        description: Optional[str] = None,
        encrypt_type: Optional[int] = None,
        file_system_type: Optional[str] = None,
        kms_key_id: Optional[str] = None,
        protocol_type: Optional[str] = None,
        storage_type: Optional[str] = None,
        tags: Optional[Mapping[str, Any]] = None,
        vpc_id: Optional[str] = None,
        vswitch_id: Optional[str] = None,
        zone_id: Optional[str] = None) -> FileSystem
func GetFileSystem(ctx *Context, name string, id IDInput, state *FileSystemState, opts ...ResourceOption) (*FileSystem, error)
public static FileSystem Get(string name, Input<string> id, FileSystemState? state, CustomResourceOptions? opts = null)
public static FileSystem get(String name, Output<String> id, FileSystemState 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:
Capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

Description string

The File System description.

EncryptType int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
FileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

KmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

ProtocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

StorageType string

The storage type of the file System.

  • Valid values:
Tags Dictionary<string, object>

A mapping of tags to assign to the resource.

VpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

VswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

ZoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

Capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

Description string

The File System description.

EncryptType int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
FileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

KmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

ProtocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

StorageType string

The storage type of the file System.

  • Valid values:
Tags map[string]interface{}

A mapping of tags to assign to the resource.

VpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

VswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

ZoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

capacity Integer

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description String

The File System description.

encryptType Integer

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType String

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId String

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

protocolType String

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType String

The storage type of the file System.

  • Valid values:
tags Map

A mapping of tags to assign to the resource.

vpcId String

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId String

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId String

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

capacity number

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description string

The File System description.

encryptType number

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType string

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId string

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

protocolType string

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType string

The storage type of the file System.

  • Valid values:
tags {[key: string]: any}

A mapping of tags to assign to the resource.

vpcId string

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId string

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId string

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

capacity int

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description str

The File System description.

encrypt_type int

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
file_system_type str

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kms_key_id str

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

protocol_type str

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storage_type str

The storage type of the file System.

  • Valid values:
tags Mapping[str, Any]

A mapping of tags to assign to the resource.

vpc_id str

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitch_id str

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zone_id str

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

capacity Number

The capacity of the file system. The capacity is required when the file_system_type is extreme. Unit: gib; Note: The minimum value is 100.

description String

The File System description.

encryptType Number

Whether the file system is encrypted. Using kms service escrow key to encrypt and store the file system data. When reading and writing encrypted data, there is no need to decrypt.

  • Valid values:
fileSystemType String

the type of the file system. Valid values: standard (Default), extreme, cpfs.

kmsKeyId String

The id of the KMS key. The kms_key_id is required when the encrypt_type is 2.

protocolType String

The protocol type of the file system. Valid values: NFS, SMB (Available when the file_system_type is standard), cpfs (Available when the file_system_type is cpfs).

storageType String

The storage type of the file System.

  • Valid values:
tags Map

A mapping of tags to assign to the resource.

vpcId String

The id of the VPC. The vpc_id is required when the file_system_type is cpfs.

vswitchId String

The id of the vSwitch. The vswitch_id is required when the file_system_type is cpfs.

zoneId String

The available zones information that supports nas.When FileSystemType=standard, this parameter is not required. Note: By default, a qualified availability zone is randomly selected according to the protocol_type and storage_type configuration.

Import

Nas File System can be imported using the id, e.g.

 $ pulumi import alicloud:nas/fileSystem:FileSystem foo 1337849c59

Package Details

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

This Pulumi package is based on the alicloud Terraform Provider.