Alibaba Cloud v3.57.1 published on Wednesday, Jun 26, 2024 by Pulumi
alicloud.cs.Swarm
Explore with Pulumi AI
Create Swarm Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Swarm(name: string, args: SwarmArgs, opts?: CustomResourceOptions);
@overload
def Swarm(resource_name: str,
args: SwarmArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Swarm(resource_name: str,
opts: Optional[ResourceOptions] = None,
instance_type: Optional[str] = None,
vswitch_id: Optional[str] = None,
password: Optional[str] = None,
cidr_block: Optional[str] = None,
name: Optional[str] = None,
is_outdated: Optional[bool] = None,
image_id: Optional[str] = None,
name_prefix: Optional[str] = None,
need_slb: Optional[bool] = None,
node_number: Optional[int] = None,
disk_size: Optional[int] = None,
release_eip: Optional[bool] = None,
size: Optional[int] = None,
disk_category: Optional[str] = None)
func NewSwarm(ctx *Context, name string, args SwarmArgs, opts ...ResourceOption) (*Swarm, error)
public Swarm(string name, SwarmArgs args, CustomResourceOptions? opts = null)
type: alicloud:cs:Swarm
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args SwarmArgs
- 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 SwarmArgs
- 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 SwarmArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SwarmArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SwarmArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var swarmResource = new AliCloud.CS.Swarm("swarmResource", new()
{
InstanceType = "string",
VswitchId = "string",
Password = "string",
CidrBlock = "string",
Name = "string",
IsOutdated = false,
ImageId = "string",
NamePrefix = "string",
NeedSlb = false,
NodeNumber = 0,
DiskSize = 0,
ReleaseEip = false,
DiskCategory = "string",
});
example, err := cs.NewSwarm(ctx, "swarmResource", &cs.SwarmArgs{
InstanceType: pulumi.String("string"),
VswitchId: pulumi.String("string"),
Password: pulumi.String("string"),
CidrBlock: pulumi.String("string"),
Name: pulumi.String("string"),
IsOutdated: pulumi.Bool(false),
ImageId: pulumi.String("string"),
NamePrefix: pulumi.String("string"),
NeedSlb: pulumi.Bool(false),
NodeNumber: pulumi.Int(0),
DiskSize: pulumi.Int(0),
ReleaseEip: pulumi.Bool(false),
DiskCategory: pulumi.String("string"),
})
var swarmResource = new Swarm("swarmResource", SwarmArgs.builder()
.instanceType("string")
.vswitchId("string")
.password("string")
.cidrBlock("string")
.name("string")
.isOutdated(false)
.imageId("string")
.namePrefix("string")
.needSlb(false)
.nodeNumber(0)
.diskSize(0)
.releaseEip(false)
.diskCategory("string")
.build());
swarm_resource = alicloud.cs.Swarm("swarmResource",
instance_type="string",
vswitch_id="string",
password="string",
cidr_block="string",
name="string",
is_outdated=False,
image_id="string",
name_prefix="string",
need_slb=False,
node_number=0,
disk_size=0,
release_eip=False,
disk_category="string")
const swarmResource = new alicloud.cs.Swarm("swarmResource", {
instanceType: "string",
vswitchId: "string",
password: "string",
cidrBlock: "string",
name: "string",
isOutdated: false,
imageId: "string",
namePrefix: "string",
needSlb: false,
nodeNumber: 0,
diskSize: 0,
releaseEip: false,
diskCategory: "string",
});
type: alicloud:cs:Swarm
properties:
cidrBlock: string
diskCategory: string
diskSize: 0
imageId: string
instanceType: string
isOutdated: false
name: string
namePrefix: string
needSlb: false
nodeNumber: 0
password: string
releaseEip: false
vswitchId: string
Swarm 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 Swarm resource accepts the following input properties:
- Cidr
Block string - Instance
Type string - Password string
- Vswitch
Id string - Disk
Category string - Disk
Size int - Image
Id string - Is
Outdated bool - Name string
- Name
Prefix string - Need
Slb bool - Node
Number int - Release
Eip bool - Size int
- Cidr
Block string - Instance
Type string - Password string
- Vswitch
Id string - Disk
Category string - Disk
Size int - Image
Id string - Is
Outdated bool - Name string
- Name
Prefix string - Need
Slb bool - Node
Number int - Release
Eip bool - Size int
- cidr
Block String - instance
Type String - password String
- vswitch
Id String - disk
Category String - disk
Size Integer - image
Id String - is
Outdated Boolean - name String
- name
Prefix String - need
Slb Boolean - node
Number Integer - release
Eip Boolean - size Integer
- cidr
Block string - instance
Type string - password string
- vswitch
Id string - disk
Category string - disk
Size number - image
Id string - is
Outdated boolean - name string
- name
Prefix string - need
Slb boolean - node
Number number - release
Eip boolean - size number
- cidr_
block str - instance_
type str - password str
- vswitch_
id str - disk_
category str - disk_
size int - image_
id str - is_
outdated bool - name str
- name_
prefix str - need_
slb bool - node_
number int - release_
eip bool - size int
- cidr
Block String - instance
Type String - password String
- vswitch
Id String - disk
Category String - disk
Size Number - image
Id String - is
Outdated Boolean - name String
- name
Prefix String - need
Slb Boolean - node
Number Number - release
Eip Boolean - size Number
Outputs
All input properties are implicitly available as output properties. Additionally, the Swarm resource produces the following output properties:
- Agent
Version string - Id string
- The provider-assigned unique ID for this managed resource.
- Nodes
List<Pulumi.
Ali Cloud. CS. Outputs. Swarm Node> - Security
Group stringId - Slb
Id string - Vpc
Id string
- Agent
Version string - Id string
- The provider-assigned unique ID for this managed resource.
- Nodes
[]Swarm
Node - Security
Group stringId - Slb
Id string - Vpc
Id string
- agent
Version String - id String
- The provider-assigned unique ID for this managed resource.
- nodes
List<Swarm
Node> - security
Group StringId - slb
Id String - vpc
Id String
- agent
Version string - id string
- The provider-assigned unique ID for this managed resource.
- nodes
Swarm
Node[] - security
Group stringId - slb
Id string - vpc
Id string
- agent_
version str - id str
- The provider-assigned unique ID for this managed resource.
- nodes
Sequence[Swarm
Node] - security_
group_ strid - slb_
id str - vpc_
id str
- agent
Version String - id String
- The provider-assigned unique ID for this managed resource.
- nodes List<Property Map>
- security
Group StringId - slb
Id String - vpc
Id String
Look up Existing Swarm Resource
Get an existing Swarm 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?: SwarmState, opts?: CustomResourceOptions): Swarm
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
agent_version: Optional[str] = None,
cidr_block: Optional[str] = None,
disk_category: Optional[str] = None,
disk_size: Optional[int] = None,
image_id: Optional[str] = None,
instance_type: Optional[str] = None,
is_outdated: Optional[bool] = None,
name: Optional[str] = None,
name_prefix: Optional[str] = None,
need_slb: Optional[bool] = None,
node_number: Optional[int] = None,
nodes: Optional[Sequence[SwarmNodeArgs]] = None,
password: Optional[str] = None,
release_eip: Optional[bool] = None,
security_group_id: Optional[str] = None,
size: Optional[int] = None,
slb_id: Optional[str] = None,
vpc_id: Optional[str] = None,
vswitch_id: Optional[str] = None) -> Swarm
func GetSwarm(ctx *Context, name string, id IDInput, state *SwarmState, opts ...ResourceOption) (*Swarm, error)
public static Swarm Get(string name, Input<string> id, SwarmState? state, CustomResourceOptions? opts = null)
public static Swarm get(String name, Output<String> id, SwarmState 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.
- Agent
Version string - Cidr
Block string - Disk
Category string - Disk
Size int - Image
Id string - Instance
Type string - Is
Outdated bool - Name string
- Name
Prefix string - Need
Slb bool - Node
Number int - Nodes
List<Pulumi.
Ali Cloud. CS. Inputs. Swarm Node> - Password string
- Release
Eip bool - Security
Group stringId - Size int
- Slb
Id string - Vpc
Id string - Vswitch
Id string
- Agent
Version string - Cidr
Block string - Disk
Category string - Disk
Size int - Image
Id string - Instance
Type string - Is
Outdated bool - Name string
- Name
Prefix string - Need
Slb bool - Node
Number int - Nodes
[]Swarm
Node Args - Password string
- Release
Eip bool - Security
Group stringId - Size int
- Slb
Id string - Vpc
Id string - Vswitch
Id string
- agent
Version String - cidr
Block String - disk
Category String - disk
Size Integer - image
Id String - instance
Type String - is
Outdated Boolean - name String
- name
Prefix String - need
Slb Boolean - node
Number Integer - nodes
List<Swarm
Node> - password String
- release
Eip Boolean - security
Group StringId - size Integer
- slb
Id String - vpc
Id String - vswitch
Id String
- agent
Version string - cidr
Block string - disk
Category string - disk
Size number - image
Id string - instance
Type string - is
Outdated boolean - name string
- name
Prefix string - need
Slb boolean - node
Number number - nodes
Swarm
Node[] - password string
- release
Eip boolean - security
Group stringId - size number
- slb
Id string - vpc
Id string - vswitch
Id string
- agent_
version str - cidr_
block str - disk_
category str - disk_
size int - image_
id str - instance_
type str - is_
outdated bool - name str
- name_
prefix str - need_
slb bool - node_
number int - nodes
Sequence[Swarm
Node Args] - password str
- release_
eip bool - security_
group_ strid - size int
- slb_
id str - vpc_
id str - vswitch_
id str
- agent
Version String - cidr
Block String - disk
Category String - disk
Size Number - image
Id String - instance
Type String - is
Outdated Boolean - name String
- name
Prefix String - need
Slb Boolean - node
Number Number - nodes List<Property Map>
- password String
- release
Eip Boolean - security
Group StringId - size Number
- slb
Id String - vpc
Id String - vswitch
Id String
Supporting Types
SwarmNode, SwarmNodeArgs
- eip str
- id str
- name str
- private_
ip str - status str
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.