File System Args
Provides a Apsara File Storage for HDFS (DFS) File System resource. For information about Apsara File Storage for HDFS (DFS) File System and how to use it, see What is File System.
NOTE: Available since v1.140.0.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "tf-example";
const _default = new alicloud.dfs.FileSystem("default", {
storageType: "PERFORMANCE",
zoneId: "cn-hangzhou-b",
protocolType: "PANGU",
description: name,
fileSystemName: name,
throughputMode: "Provisioned",
spaceCapacity: 1024,
provisionedThroughputInMiBps: 512,
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "tf-example"
default = alicloud.dfs.FileSystem("default",
storage_type="PERFORMANCE",
zone_id="cn-hangzhou-b",
protocol_type="PANGU",
description=name,
file_system_name=name,
throughput_mode="Provisioned",
space_capacity=1024,
provisioned_throughput_in_mi_bps=512)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "tf-example";
var @default = new AliCloud.Dfs.FileSystem("default", new()
{
StorageType = "PERFORMANCE",
ZoneId = "cn-hangzhou-b",
ProtocolType = "PANGU",
Description = name,
FileSystemName = name,
ThroughputMode = "Provisioned",
SpaceCapacity = 1024,
ProvisionedThroughputInMiBps = 512,
});
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dfs"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "tf-example"
if param := cfg.Get("name"); param != "" {
name = param
}
_, err := dfs.NewFileSystem(ctx, "default", &dfs.FileSystemArgs{
StorageType: pulumi.String("PERFORMANCE"),
ZoneId: pulumi.String("cn-hangzhou-b"),
ProtocolType: pulumi.String("PANGU"),
Description: pulumi.String(name),
FileSystemName: pulumi.String(name),
ThroughputMode: pulumi.String("Provisioned"),
SpaceCapacity: pulumi.Int(1024),
ProvisionedThroughputInMiBps: pulumi.Int(512),
})
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.dfs.FileSystem;
import com.pulumi.alicloud.dfs.FileSystemArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var config = ctx.config();
final var name = config.get("name").orElse("tf-example");
var default_ = new FileSystem("default", FileSystemArgs.builder()
.storageType("PERFORMANCE")
.zoneId("cn-hangzhou-b")
.protocolType("PANGU")
.description(name)
.fileSystemName(name)
.throughputMode("Provisioned")
.spaceCapacity(1024)
.provisionedThroughputInMiBps(512)
.build());
}
}
configuration:
name:
type: string
default: tf-example
resources:
default:
type: alicloud:dfs:FileSystem
properties:
storageType: PERFORMANCE
zoneId: cn-hangzhou-b
protocolType: PANGU
description: ${name}
fileSystemName: ${name}
throughputMode: Provisioned
spaceCapacity: '1024'
provisionedThroughputInMiBps: '512'
Import
Apsara File Storage for HDFS (DFS) File System can be imported using the id, e.g.
$ pulumi import alicloud:dfs/fileSystem:FileSystem example <id>
Constructors
Properties
Redundancy mode of the file system. Value:
Dedicated cluster id, which is used to support scenarios such as group cloud migration.
The description of the file system resource. No more than 32 characters in length.
The file system name. The naming rules are as follows: The length is 6~64 characters. Globally unique and cannot be an empty string. English letters are supported and can contain numbers, underscores (_), and dashes (-).
Save set sequence number, the user selects the content of the specified sequence number in the Save set.
The protocol type. Value: HDFS
, PANGU
.
Provisioned throughput. This parameter is required when ThroughputMode is set to Provisioned. Unit: MB/s Value range: 1~5120.
File system capacity. When the actual amount of data stored reaches the capacity of the file system, data cannot be written. Unit: GiB.
Save set identity, used to select a user-specified save set.
The storage media type. Value: STANDARD (default): STANDARD PERFORMANCE: PERFORMANCE type.
The throughput mode. Value: Standard (default): Standard throughput Provisioned: preset throughput.