1. Packages
  2. Alibaba Cloud Provider
  3. API Docs
  4. eflo
  5. NodeGroup
Alibaba Cloud v3.76.0 published on Tuesday, Apr 8, 2025 by Pulumi

alicloud.eflo.NodeGroup

Explore with Pulumi AI

Provides a Eflo Node Group resource.

Node group. Divide a cluster into multiple node groups, each containing multiple nodes.

For information about Eflo Node Group and how to use it, see What is Node Group.

NOTE: Available since v1.246.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") || "terraform-example";
const _default = alicloud.resourcemanager.getResourceGroups({});
const createVpc = new alicloud.vpc.Network("create_vpc", {
    cidrBlock: "192.168.0.0/16",
    vpcName: "cluster-resoure-example",
});
const createVswitch = new alicloud.vpc.Switch("create_vswitch", {
    vpcId: createVpc.id,
    zoneId: "cn-hangzhou-b",
    cidrBlock: "192.168.0.0/24",
    vswitchName: "cluster-resoure-example",
});
const createSecurityGroup = new alicloud.ecs.SecurityGroup("create_security_group", {
    description: "sg",
    securityGroupName: "cluster-resoure-example",
    securityGroupType: "normal",
    vpcId: createVpc.id,
});
const defaultCluster = new alicloud.eflo.Cluster("default", {
    clusterDescription: "cluster-resource-example",
    openEniJumboFrame: false,
    hpnZone: "B1",
    nimizVswitches: ["1111"],
    ignoreFailedNodeTasks: true,
    resourceGroupId: _default.then(_default => _default.ids?.[1]),
    nodeGroups: [{
        imageId: "i198448731735114628708",
        zoneId: "cn-hangzhou-b",
        nodeGroupName: "cluster-resource-example",
        nodeGroupDescription: "cluster-resource-example",
        machineType: "efg2.C48cA3sen",
    }],
    networks: {
        tailIpVersion: "ipv4",
        newVpdInfo: {
            monitorVpcId: createVpc.id,
            monitorVswitchId: createVswitch.id,
            cenId: "11111",
            cloudLinkId: "1111",
            vpdCidr: "111",
            vpdSubnets: [{
                zoneId: "1111",
                subnetCidr: "111",
                subnetType: "111",
            }],
            cloudLinkCidr: "169.254.128.0/23",
        },
        securityGroupId: createSecurityGroup.id,
        vswitchZoneId: "cn-hangzhou-b",
        vpcId: createVpc.id,
        vswitchId: createVswitch.id,
        vpdInfo: {
            vpdId: "111",
            vpdSubnets: ["111"],
        },
        ipAllocationPolicies: [{
            bondPolicy: {
                bondDefaultSubnet: "111",
                bonds: [{
                    name: "111",
                    subnet: "111",
                }],
            },
            machineTypePolicies: [{
                bonds: [{
                    name: "111",
                    subnet: "111",
                }],
                machineType: "111",
            }],
            nodePolicies: [{
                bonds: [{
                    name: "111",
                    subnet: "111",
                }],
                nodeId: "111",
            }],
        }],
    },
    clusterName: "tfacceflo7165",
    clusterType: "Lite",
});
const defaultNode = new alicloud.eflo.Node("default", {
    period: 36,
    discountLevel: "36",
    billingCycle: "1month",
    classify: "gpuserver",
    zone: "cn-hangzhou-b",
    productForm: "instance",
    paymentRatio: "0",
    hpnZone: "B1",
    serverArch: "bmserver",
    computingServer: "efg1.nvga1n",
    stageNum: "36",
    renewalStatus: "AutoRenewal",
    renewPeriod: 36,
    status: "Unused",
});
const defaultNodeGroup = new alicloud.eflo.NodeGroup("default", {
    nodes: [{
        nodeId: defaultNode.id,
        vpcId: createVpc.id,
        vswitchId: createVswitch.id,
        hostname: "jxyhostname",
        loginPassword: "Alibaba@2025",
    }],
    ignoreFailedNodeTasks: true,
    clusterId: defaultCluster.id,
    imageId: "i195048661660874208657",
    zoneId: "cn-hangzhou-b",
    vpdSubnets: ["example"],
    userData: "YWxpLGFsaSxhbGliYWJh",
    vswitchZoneId: "cn-hangzhou-b",
    ipAllocationPolicies: [{
        bondPolicy: {
            bondDefaultSubnet: "example",
            bonds: [{
                name: "example",
                subnet: "example",
            }],
        },
        machineTypePolicies: [{
            bonds: [{
                name: "example",
                subnet: "example",
            }],
            machineType: "example",
        }],
        nodePolicies: [{
            nodeId: defaultNode.id,
            bonds: [{
                name: "example",
                subnet: "example",
            }],
        }],
    }],
    machineType: "efg1.nvga1",
    az: "cn-hangzhou-b",
    nodeGroupDescription: "resource-example1",
    nodeGroupName: "tfacceflo63657_update",
});
Copy
import pulumi
import pulumi_alicloud as alicloud

config = pulumi.Config()
name = config.get("name")
if name is None:
    name = "terraform-example"
default = alicloud.resourcemanager.get_resource_groups()
create_vpc = alicloud.vpc.Network("create_vpc",
    cidr_block="192.168.0.0/16",
    vpc_name="cluster-resoure-example")
create_vswitch = alicloud.vpc.Switch("create_vswitch",
    vpc_id=create_vpc.id,
    zone_id="cn-hangzhou-b",
    cidr_block="192.168.0.0/24",
    vswitch_name="cluster-resoure-example")
create_security_group = alicloud.ecs.SecurityGroup("create_security_group",
    description="sg",
    security_group_name="cluster-resoure-example",
    security_group_type="normal",
    vpc_id=create_vpc.id)
default_cluster = alicloud.eflo.Cluster("default",
    cluster_description="cluster-resource-example",
    open_eni_jumbo_frame=False,
    hpn_zone="B1",
    nimiz_vswitches=["1111"],
    ignore_failed_node_tasks=True,
    resource_group_id=default.ids[1],
    node_groups=[{
        "image_id": "i198448731735114628708",
        "zone_id": "cn-hangzhou-b",
        "node_group_name": "cluster-resource-example",
        "node_group_description": "cluster-resource-example",
        "machine_type": "efg2.C48cA3sen",
    }],
    networks={
        "tail_ip_version": "ipv4",
        "new_vpd_info": {
            "monitor_vpc_id": create_vpc.id,
            "monitor_vswitch_id": create_vswitch.id,
            "cen_id": "11111",
            "cloud_link_id": "1111",
            "vpd_cidr": "111",
            "vpd_subnets": [{
                "zone_id": "1111",
                "subnet_cidr": "111",
                "subnet_type": "111",
            }],
            "cloud_link_cidr": "169.254.128.0/23",
        },
        "security_group_id": create_security_group.id,
        "vswitch_zone_id": "cn-hangzhou-b",
        "vpc_id": create_vpc.id,
        "vswitch_id": create_vswitch.id,
        "vpd_info": {
            "vpd_id": "111",
            "vpd_subnets": ["111"],
        },
        "ip_allocation_policies": [{
            "bond_policy": {
                "bond_default_subnet": "111",
                "bonds": [{
                    "name": "111",
                    "subnet": "111",
                }],
            },
            "machine_type_policies": [{
                "bonds": [{
                    "name": "111",
                    "subnet": "111",
                }],
                "machine_type": "111",
            }],
            "node_policies": [{
                "bonds": [{
                    "name": "111",
                    "subnet": "111",
                }],
                "node_id": "111",
            }],
        }],
    },
    cluster_name="tfacceflo7165",
    cluster_type="Lite")
default_node = alicloud.eflo.Node("default",
    period=36,
    discount_level="36",
    billing_cycle="1month",
    classify="gpuserver",
    zone="cn-hangzhou-b",
    product_form="instance",
    payment_ratio="0",
    hpn_zone="B1",
    server_arch="bmserver",
    computing_server="efg1.nvga1n",
    stage_num="36",
    renewal_status="AutoRenewal",
    renew_period=36,
    status="Unused")
default_node_group = alicloud.eflo.NodeGroup("default",
    nodes=[{
        "node_id": default_node.id,
        "vpc_id": create_vpc.id,
        "vswitch_id": create_vswitch.id,
        "hostname": "jxyhostname",
        "login_password": "Alibaba@2025",
    }],
    ignore_failed_node_tasks=True,
    cluster_id=default_cluster.id,
    image_id="i195048661660874208657",
    zone_id="cn-hangzhou-b",
    vpd_subnets=["example"],
    user_data="YWxpLGFsaSxhbGliYWJh",
    vswitch_zone_id="cn-hangzhou-b",
    ip_allocation_policies=[{
        "bond_policy": {
            "bond_default_subnet": "example",
            "bonds": [{
                "name": "example",
                "subnet": "example",
            }],
        },
        "machine_type_policies": [{
            "bonds": [{
                "name": "example",
                "subnet": "example",
            }],
            "machine_type": "example",
        }],
        "node_policies": [{
            "node_id": default_node.id,
            "bonds": [{
                "name": "example",
                "subnet": "example",
            }],
        }],
    }],
    machine_type="efg1.nvga1",
    az="cn-hangzhou-b",
    node_group_description="resource-example1",
    node_group_name="tfacceflo63657_update")
Copy
package main

import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/ecs"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/eflo"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/resourcemanager"
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
	"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 := "terraform-example"
		if param := cfg.Get("name"); param != "" {
			name = param
		}
		_default, err := resourcemanager.GetResourceGroups(ctx, &resourcemanager.GetResourceGroupsArgs{}, nil)
		if err != nil {
			return err
		}
		createVpc, err := vpc.NewNetwork(ctx, "create_vpc", &vpc.NetworkArgs{
			CidrBlock: pulumi.String("192.168.0.0/16"),
			VpcName:   pulumi.String("cluster-resoure-example"),
		})
		if err != nil {
			return err
		}
		createVswitch, err := vpc.NewSwitch(ctx, "create_vswitch", &vpc.SwitchArgs{
			VpcId:       createVpc.ID(),
			ZoneId:      pulumi.String("cn-hangzhou-b"),
			CidrBlock:   pulumi.String("192.168.0.0/24"),
			VswitchName: pulumi.String("cluster-resoure-example"),
		})
		if err != nil {
			return err
		}
		createSecurityGroup, err := ecs.NewSecurityGroup(ctx, "create_security_group", &ecs.SecurityGroupArgs{
			Description:       pulumi.String("sg"),
			SecurityGroupName: pulumi.String("cluster-resoure-example"),
			SecurityGroupType: pulumi.String("normal"),
			VpcId:             createVpc.ID(),
		})
		if err != nil {
			return err
		}
		defaultCluster, err := eflo.NewCluster(ctx, "default", &eflo.ClusterArgs{
			ClusterDescription: pulumi.String("cluster-resource-example"),
			OpenEniJumboFrame:  pulumi.Bool(false),
			HpnZone:            pulumi.String("B1"),
			NimizVswitches: pulumi.StringArray{
				pulumi.String("1111"),
			},
			IgnoreFailedNodeTasks: pulumi.Bool(true),
			ResourceGroupId:       pulumi.String(_default.Ids[1]),
			NodeGroups: eflo.ClusterNodeGroupArray{
				&eflo.ClusterNodeGroupArgs{
					ImageId:              pulumi.String("i198448731735114628708"),
					ZoneId:               pulumi.String("cn-hangzhou-b"),
					NodeGroupName:        pulumi.String("cluster-resource-example"),
					NodeGroupDescription: pulumi.String("cluster-resource-example"),
					MachineType:          pulumi.String("efg2.C48cA3sen"),
				},
			},
			Networks: &eflo.ClusterNetworksArgs{
				TailIpVersion: pulumi.String("ipv4"),
				NewVpdInfo: &eflo.ClusterNetworksNewVpdInfoArgs{
					MonitorVpcId:     createVpc.ID(),
					MonitorVswitchId: createVswitch.ID(),
					CenId:            pulumi.String("11111"),
					CloudLinkId:      pulumi.String("1111"),
					VpdCidr:          pulumi.String("111"),
					VpdSubnets: eflo.ClusterNetworksNewVpdInfoVpdSubnetArray{
						&eflo.ClusterNetworksNewVpdInfoVpdSubnetArgs{
							ZoneId:     pulumi.String("1111"),
							SubnetCidr: pulumi.String("111"),
							SubnetType: pulumi.String("111"),
						},
					},
					CloudLinkCidr: pulumi.String("169.254.128.0/23"),
				},
				SecurityGroupId: createSecurityGroup.ID(),
				VswitchZoneId:   pulumi.String("cn-hangzhou-b"),
				VpcId:           createVpc.ID(),
				VswitchId:       createVswitch.ID(),
				VpdInfo: &eflo.ClusterNetworksVpdInfoArgs{
					VpdId: pulumi.String("111"),
					VpdSubnets: pulumi.StringArray{
						pulumi.String("111"),
					},
				},
				IpAllocationPolicies: eflo.ClusterNetworksIpAllocationPolicyArray{
					&eflo.ClusterNetworksIpAllocationPolicyArgs{
						BondPolicy: &eflo.ClusterNetworksIpAllocationPolicyBondPolicyArgs{
							BondDefaultSubnet: pulumi.String("111"),
							Bonds: eflo.ClusterNetworksIpAllocationPolicyBondPolicyBondArray{
								&eflo.ClusterNetworksIpAllocationPolicyBondPolicyBondArgs{
									Name:   pulumi.String("111"),
									Subnet: pulumi.String("111"),
								},
							},
						},
						MachineTypePolicies: eflo.ClusterNetworksIpAllocationPolicyMachineTypePolicyArray{
							&eflo.ClusterNetworksIpAllocationPolicyMachineTypePolicyArgs{
								Bonds: eflo.ClusterNetworksIpAllocationPolicyMachineTypePolicyBondArray{
									&eflo.ClusterNetworksIpAllocationPolicyMachineTypePolicyBondArgs{
										Name:   pulumi.String("111"),
										Subnet: pulumi.String("111"),
									},
								},
								MachineType: pulumi.String("111"),
							},
						},
						NodePolicies: eflo.ClusterNetworksIpAllocationPolicyNodePolicyArray{
							&eflo.ClusterNetworksIpAllocationPolicyNodePolicyArgs{
								Bonds: eflo.ClusterNetworksIpAllocationPolicyNodePolicyBondArray{
									&eflo.ClusterNetworksIpAllocationPolicyNodePolicyBondArgs{
										Name:   pulumi.String("111"),
										Subnet: pulumi.String("111"),
									},
								},
								NodeId: pulumi.String("111"),
							},
						},
					},
				},
			},
			ClusterName: pulumi.String("tfacceflo7165"),
			ClusterType: pulumi.String("Lite"),
		})
		if err != nil {
			return err
		}
		defaultNode, err := eflo.NewNode(ctx, "default", &eflo.NodeArgs{
			Period:          pulumi.Int(36),
			DiscountLevel:   pulumi.String("36"),
			BillingCycle:    pulumi.String("1month"),
			Classify:        pulumi.String("gpuserver"),
			Zone:            pulumi.String("cn-hangzhou-b"),
			ProductForm:     pulumi.String("instance"),
			PaymentRatio:    pulumi.String("0"),
			HpnZone:         pulumi.String("B1"),
			ServerArch:      pulumi.String("bmserver"),
			ComputingServer: pulumi.String("efg1.nvga1n"),
			StageNum:        pulumi.String("36"),
			RenewalStatus:   pulumi.String("AutoRenewal"),
			RenewPeriod:     pulumi.Int(36),
			Status:          pulumi.String("Unused"),
		})
		if err != nil {
			return err
		}
		_, err = eflo.NewNodeGroup(ctx, "default", &eflo.NodeGroupArgs{
			Nodes: eflo.NodeGroupNodeArray{
				&eflo.NodeGroupNodeArgs{
					NodeId:        defaultNode.ID(),
					VpcId:         createVpc.ID(),
					VswitchId:     createVswitch.ID(),
					Hostname:      pulumi.String("jxyhostname"),
					LoginPassword: pulumi.String("Alibaba@2025"),
				},
			},
			IgnoreFailedNodeTasks: pulumi.Bool(true),
			ClusterId:             defaultCluster.ID(),
			ImageId:               pulumi.String("i195048661660874208657"),
			ZoneId:                pulumi.String("cn-hangzhou-b"),
			VpdSubnets: pulumi.StringArray{
				pulumi.String("example"),
			},
			UserData:      pulumi.String("YWxpLGFsaSxhbGliYWJh"),
			VswitchZoneId: pulumi.String("cn-hangzhou-b"),
			IpAllocationPolicies: eflo.NodeGroupIpAllocationPolicyArray{
				&eflo.NodeGroupIpAllocationPolicyArgs{
					BondPolicy: &eflo.NodeGroupIpAllocationPolicyBondPolicyArgs{
						BondDefaultSubnet: pulumi.String("example"),
						Bonds: eflo.NodeGroupIpAllocationPolicyBondPolicyBondArray{
							&eflo.NodeGroupIpAllocationPolicyBondPolicyBondArgs{
								Name:   pulumi.String("example"),
								Subnet: pulumi.String("example"),
							},
						},
					},
					MachineTypePolicies: eflo.NodeGroupIpAllocationPolicyMachineTypePolicyArray{
						&eflo.NodeGroupIpAllocationPolicyMachineTypePolicyArgs{
							Bonds: eflo.NodeGroupIpAllocationPolicyMachineTypePolicyBondArray{
								&eflo.NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs{
									Name:   pulumi.String("example"),
									Subnet: pulumi.String("example"),
								},
							},
							MachineType: pulumi.String("example"),
						},
					},
					NodePolicies: eflo.NodeGroupIpAllocationPolicyNodePolicyArray{
						&eflo.NodeGroupIpAllocationPolicyNodePolicyArgs{
							NodeId: defaultNode.ID(),
							Bonds: eflo.NodeGroupIpAllocationPolicyNodePolicyBondArray{
								&eflo.NodeGroupIpAllocationPolicyNodePolicyBondArgs{
									Name:   pulumi.String("example"),
									Subnet: pulumi.String("example"),
								},
							},
						},
					},
				},
			},
			MachineType:          pulumi.String("efg1.nvga1"),
			Az:                   pulumi.String("cn-hangzhou-b"),
			NodeGroupDescription: pulumi.String("resource-example1"),
			NodeGroupName:        pulumi.String("tfacceflo63657_update"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
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") ?? "terraform-example";
    var @default = AliCloud.ResourceManager.GetResourceGroups.Invoke();

    var createVpc = new AliCloud.Vpc.Network("create_vpc", new()
    {
        CidrBlock = "192.168.0.0/16",
        VpcName = "cluster-resoure-example",
    });

    var createVswitch = new AliCloud.Vpc.Switch("create_vswitch", new()
    {
        VpcId = createVpc.Id,
        ZoneId = "cn-hangzhou-b",
        CidrBlock = "192.168.0.0/24",
        VswitchName = "cluster-resoure-example",
    });

    var createSecurityGroup = new AliCloud.Ecs.SecurityGroup("create_security_group", new()
    {
        Description = "sg",
        SecurityGroupName = "cluster-resoure-example",
        SecurityGroupType = "normal",
        VpcId = createVpc.Id,
    });

    var defaultCluster = new AliCloud.Eflo.Cluster("default", new()
    {
        ClusterDescription = "cluster-resource-example",
        OpenEniJumboFrame = false,
        HpnZone = "B1",
        NimizVswitches = new[]
        {
            "1111",
        },
        IgnoreFailedNodeTasks = true,
        ResourceGroupId = @default.Apply(@default => @default.Apply(getResourceGroupsResult => getResourceGroupsResult.Ids[1])),
        NodeGroups = new[]
        {
            new AliCloud.Eflo.Inputs.ClusterNodeGroupArgs
            {
                ImageId = "i198448731735114628708",
                ZoneId = "cn-hangzhou-b",
                NodeGroupName = "cluster-resource-example",
                NodeGroupDescription = "cluster-resource-example",
                MachineType = "efg2.C48cA3sen",
            },
        },
        Networks = new AliCloud.Eflo.Inputs.ClusterNetworksArgs
        {
            TailIpVersion = "ipv4",
            NewVpdInfo = new AliCloud.Eflo.Inputs.ClusterNetworksNewVpdInfoArgs
            {
                MonitorVpcId = createVpc.Id,
                MonitorVswitchId = createVswitch.Id,
                CenId = "11111",
                CloudLinkId = "1111",
                VpdCidr = "111",
                VpdSubnets = new[]
                {
                    new AliCloud.Eflo.Inputs.ClusterNetworksNewVpdInfoVpdSubnetArgs
                    {
                        ZoneId = "1111",
                        SubnetCidr = "111",
                        SubnetType = "111",
                    },
                },
                CloudLinkCidr = "169.254.128.0/23",
            },
            SecurityGroupId = createSecurityGroup.Id,
            VswitchZoneId = "cn-hangzhou-b",
            VpcId = createVpc.Id,
            VswitchId = createVswitch.Id,
            VpdInfo = new AliCloud.Eflo.Inputs.ClusterNetworksVpdInfoArgs
            {
                VpdId = "111",
                VpdSubnets = new[]
                {
                    "111",
                },
            },
            IpAllocationPolicies = new[]
            {
                new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyArgs
                {
                    BondPolicy = new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyBondPolicyArgs
                    {
                        BondDefaultSubnet = "111",
                        Bonds = new[]
                        {
                            new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyBondPolicyBondArgs
                            {
                                Name = "111",
                                Subnet = "111",
                            },
                        },
                    },
                    MachineTypePolicies = new[]
                    {
                        new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyMachineTypePolicyArgs
                        {
                            Bonds = new[]
                            {
                                new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyMachineTypePolicyBondArgs
                                {
                                    Name = "111",
                                    Subnet = "111",
                                },
                            },
                            MachineType = "111",
                        },
                    },
                    NodePolicies = new[]
                    {
                        new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyNodePolicyArgs
                        {
                            Bonds = new[]
                            {
                                new AliCloud.Eflo.Inputs.ClusterNetworksIpAllocationPolicyNodePolicyBondArgs
                                {
                                    Name = "111",
                                    Subnet = "111",
                                },
                            },
                            NodeId = "111",
                        },
                    },
                },
            },
        },
        ClusterName = "tfacceflo7165",
        ClusterType = "Lite",
    });

    var defaultNode = new AliCloud.Eflo.Node("default", new()
    {
        Period = 36,
        DiscountLevel = "36",
        BillingCycle = "1month",
        Classify = "gpuserver",
        Zone = "cn-hangzhou-b",
        ProductForm = "instance",
        PaymentRatio = "0",
        HpnZone = "B1",
        ServerArch = "bmserver",
        ComputingServer = "efg1.nvga1n",
        StageNum = "36",
        RenewalStatus = "AutoRenewal",
        RenewPeriod = 36,
        Status = "Unused",
    });

    var defaultNodeGroup = new AliCloud.Eflo.NodeGroup("default", new()
    {
        Nodes = new[]
        {
            new AliCloud.Eflo.Inputs.NodeGroupNodeArgs
            {
                NodeId = defaultNode.Id,
                VpcId = createVpc.Id,
                VswitchId = createVswitch.Id,
                Hostname = "jxyhostname",
                LoginPassword = "Alibaba@2025",
            },
        },
        IgnoreFailedNodeTasks = true,
        ClusterId = defaultCluster.Id,
        ImageId = "i195048661660874208657",
        ZoneId = "cn-hangzhou-b",
        VpdSubnets = new[]
        {
            "example",
        },
        UserData = "YWxpLGFsaSxhbGliYWJh",
        VswitchZoneId = "cn-hangzhou-b",
        IpAllocationPolicies = new[]
        {
            new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyArgs
            {
                BondPolicy = new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicyArgs
                {
                    BondDefaultSubnet = "example",
                    Bonds = new[]
                    {
                        new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicyBondArgs
                        {
                            Name = "example",
                            Subnet = "example",
                        },
                    },
                },
                MachineTypePolicies = new[]
                {
                    new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyMachineTypePolicyArgs
                    {
                        Bonds = new[]
                        {
                            new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs
                            {
                                Name = "example",
                                Subnet = "example",
                            },
                        },
                        MachineType = "example",
                    },
                },
                NodePolicies = new[]
                {
                    new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyNodePolicyArgs
                    {
                        NodeId = defaultNode.Id,
                        Bonds = new[]
                        {
                            new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyNodePolicyBondArgs
                            {
                                Name = "example",
                                Subnet = "example",
                            },
                        },
                    },
                },
            },
        },
        MachineType = "efg1.nvga1",
        Az = "cn-hangzhou-b",
        NodeGroupDescription = "resource-example1",
        NodeGroupName = "tfacceflo63657_update",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourcemanagerFunctions;
import com.pulumi.alicloud.resourcemanager.inputs.GetResourceGroupsArgs;
import com.pulumi.alicloud.vpc.Network;
import com.pulumi.alicloud.vpc.NetworkArgs;
import com.pulumi.alicloud.vpc.Switch;
import com.pulumi.alicloud.vpc.SwitchArgs;
import com.pulumi.alicloud.ecs.SecurityGroup;
import com.pulumi.alicloud.ecs.SecurityGroupArgs;
import com.pulumi.alicloud.eflo.Cluster;
import com.pulumi.alicloud.eflo.ClusterArgs;
import com.pulumi.alicloud.eflo.inputs.ClusterNodeGroupArgs;
import com.pulumi.alicloud.eflo.inputs.ClusterNetworksArgs;
import com.pulumi.alicloud.eflo.inputs.ClusterNetworksNewVpdInfoArgs;
import com.pulumi.alicloud.eflo.inputs.ClusterNetworksVpdInfoArgs;
import com.pulumi.alicloud.eflo.Node;
import com.pulumi.alicloud.eflo.NodeArgs;
import com.pulumi.alicloud.eflo.NodeGroup;
import com.pulumi.alicloud.eflo.NodeGroupArgs;
import com.pulumi.alicloud.eflo.inputs.NodeGroupNodeArgs;
import com.pulumi.alicloud.eflo.inputs.NodeGroupIpAllocationPolicyArgs;
import com.pulumi.alicloud.eflo.inputs.NodeGroupIpAllocationPolicyBondPolicyArgs;
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("terraform-example");
        final var default = ResourcemanagerFunctions.getResourceGroups();

        var createVpc = new Network("createVpc", NetworkArgs.builder()
            .cidrBlock("192.168.0.0/16")
            .vpcName("cluster-resoure-example")
            .build());

        var createVswitch = new Switch("createVswitch", SwitchArgs.builder()
            .vpcId(createVpc.id())
            .zoneId("cn-hangzhou-b")
            .cidrBlock("192.168.0.0/24")
            .vswitchName("cluster-resoure-example")
            .build());

        var createSecurityGroup = new SecurityGroup("createSecurityGroup", SecurityGroupArgs.builder()
            .description("sg")
            .securityGroupName("cluster-resoure-example")
            .securityGroupType("normal")
            .vpcId(createVpc.id())
            .build());

        var defaultCluster = new Cluster("defaultCluster", ClusterArgs.builder()
            .clusterDescription("cluster-resource-example")
            .openEniJumboFrame("false")
            .hpnZone("B1")
            .nimizVswitches("1111")
            .ignoreFailedNodeTasks("true")
            .resourceGroupId(default_.ids()[1])
            .nodeGroups(ClusterNodeGroupArgs.builder()
                .imageId("i198448731735114628708")
                .zoneId("cn-hangzhou-b")
                .nodeGroupName("cluster-resource-example")
                .nodeGroupDescription("cluster-resource-example")
                .machineType("efg2.C48cA3sen")
                .build())
            .networks(ClusterNetworksArgs.builder()
                .tailIpVersion("ipv4")
                .newVpdInfo(ClusterNetworksNewVpdInfoArgs.builder()
                    .monitorVpcId(createVpc.id())
                    .monitorVswitchId(createVswitch.id())
                    .cenId("11111")
                    .cloudLinkId("1111")
                    .vpdCidr("111")
                    .vpdSubnets(ClusterNetworksNewVpdInfoVpdSubnetArgs.builder()
                        .zoneId("1111")
                        .subnetCidr("111")
                        .subnetType("111")
                        .build())
                    .cloudLinkCidr("169.254.128.0/23")
                    .build())
                .securityGroupId(createSecurityGroup.id())
                .vswitchZoneId("cn-hangzhou-b")
                .vpcId(createVpc.id())
                .vswitchId(createVswitch.id())
                .vpdInfo(ClusterNetworksVpdInfoArgs.builder()
                    .vpdId("111")
                    .vpdSubnets("111")
                    .build())
                .ipAllocationPolicies(ClusterNetworksIpAllocationPolicyArgs.builder()
                    .bondPolicy(ClusterNetworksIpAllocationPolicyBondPolicyArgs.builder()
                        .bondDefaultSubnet("111")
                        .bonds(ClusterNetworksIpAllocationPolicyBondPolicyBondArgs.builder()
                            .name("111")
                            .subnet("111")
                            .build())
                        .build())
                    .machineTypePolicies(ClusterNetworksIpAllocationPolicyMachineTypePolicyArgs.builder()
                        .bonds(ClusterNetworksIpAllocationPolicyMachineTypePolicyBondArgs.builder()
                            .name("111")
                            .subnet("111")
                            .build())
                        .machineType("111")
                        .build())
                    .nodePolicies(ClusterNetworksIpAllocationPolicyNodePolicyArgs.builder()
                        .bonds(ClusterNetworksIpAllocationPolicyNodePolicyBondArgs.builder()
                            .name("111")
                            .subnet("111")
                            .build())
                        .nodeId("111")
                        .build())
                    .build())
                .build())
            .clusterName("tfacceflo7165")
            .clusterType("Lite")
            .build());

        var defaultNode = new Node("defaultNode", NodeArgs.builder()
            .period("36")
            .discountLevel("36")
            .billingCycle("1month")
            .classify("gpuserver")
            .zone("cn-hangzhou-b")
            .productForm("instance")
            .paymentRatio("0")
            .hpnZone("B1")
            .serverArch("bmserver")
            .computingServer("efg1.nvga1n")
            .stageNum("36")
            .renewalStatus("AutoRenewal")
            .renewPeriod("36")
            .status("Unused")
            .build());

        var defaultNodeGroup = new NodeGroup("defaultNodeGroup", NodeGroupArgs.builder()
            .nodes(NodeGroupNodeArgs.builder()
                .nodeId(defaultNode.id())
                .vpcId(createVpc.id())
                .vswitchId(createVswitch.id())
                .hostname("jxyhostname")
                .loginPassword("Alibaba@2025")
                .build())
            .ignoreFailedNodeTasks("true")
            .clusterId(defaultCluster.id())
            .imageId("i195048661660874208657")
            .zoneId("cn-hangzhou-b")
            .vpdSubnets("example")
            .userData("YWxpLGFsaSxhbGliYWJh")
            .vswitchZoneId("cn-hangzhou-b")
            .ipAllocationPolicies(NodeGroupIpAllocationPolicyArgs.builder()
                .bondPolicy(NodeGroupIpAllocationPolicyBondPolicyArgs.builder()
                    .bondDefaultSubnet("example")
                    .bonds(NodeGroupIpAllocationPolicyBondPolicyBondArgs.builder()
                        .name("example")
                        .subnet("example")
                        .build())
                    .build())
                .machineTypePolicies(NodeGroupIpAllocationPolicyMachineTypePolicyArgs.builder()
                    .bonds(NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs.builder()
                        .name("example")
                        .subnet("example")
                        .build())
                    .machineType("example")
                    .build())
                .nodePolicies(NodeGroupIpAllocationPolicyNodePolicyArgs.builder()
                    .nodeId(defaultNode.id())
                    .bonds(NodeGroupIpAllocationPolicyNodePolicyBondArgs.builder()
                        .name("example")
                        .subnet("example")
                        .build())
                    .build())
                .build())
            .machineType("efg1.nvga1")
            .az("cn-hangzhou-b")
            .nodeGroupDescription("resource-example1")
            .nodeGroupName("tfacceflo63657_update")
            .build());

    }
}
Copy
configuration:
  # Before executing this example, you need to confirm with the product team whether the resources are sufficient or you will get an error message with "Failure to check order before create instance"
  name:
    type: string
    default: terraform-example
resources:
  createVpc:
    type: alicloud:vpc:Network
    name: create_vpc
    properties:
      cidrBlock: 192.168.0.0/16
      vpcName: cluster-resoure-example
  createVswitch:
    type: alicloud:vpc:Switch
    name: create_vswitch
    properties:
      vpcId: ${createVpc.id}
      zoneId: cn-hangzhou-b
      cidrBlock: 192.168.0.0/24
      vswitchName: cluster-resoure-example
  createSecurityGroup:
    type: alicloud:ecs:SecurityGroup
    name: create_security_group
    properties:
      description: sg
      securityGroupName: cluster-resoure-example
      securityGroupType: normal
      vpcId: ${createVpc.id}
  defaultCluster:
    type: alicloud:eflo:Cluster
    name: default
    properties:
      clusterDescription: cluster-resource-example
      openEniJumboFrame: 'false'
      hpnZone: B1
      nimizVswitches:
        - '1111'
      ignoreFailedNodeTasks: 'true'
      resourceGroupId: ${default.ids[1]}
      nodeGroups:
        - imageId: i198448731735114628708
          zoneId: cn-hangzhou-b
          nodeGroupName: cluster-resource-example
          nodeGroupDescription: cluster-resource-example
          machineType: efg2.C48cA3sen
      networks:
        tailIpVersion: ipv4
        newVpdInfo:
          monitorVpcId: ${createVpc.id}
          monitorVswitchId: ${createVswitch.id}
          cenId: '11111'
          cloudLinkId: '1111'
          vpdCidr: '111'
          vpdSubnets:
            - zoneId: '1111'
              subnetCidr: '111'
              subnetType: '111'
          cloudLinkCidr: 169.254.128.0/23
        securityGroupId: ${createSecurityGroup.id}
        vswitchZoneId: cn-hangzhou-b
        vpcId: ${createVpc.id}
        vswitchId: ${createVswitch.id}
        vpdInfo:
          vpdId: '111'
          vpdSubnets:
            - '111'
        ipAllocationPolicies:
          - bondPolicy:
              bondDefaultSubnet: '111'
              bonds:
                - name: '111'
                  subnet: '111'
            machineTypePolicies:
              - bonds:
                  - name: '111'
                    subnet: '111'
                machineType: '111'
            nodePolicies:
              - bonds:
                  - name: '111'
                    subnet: '111'
                nodeId: '111'
      clusterName: tfacceflo7165
      clusterType: Lite
  defaultNode:
    type: alicloud:eflo:Node
    name: default
    properties:
      period: '36'
      discountLevel: '36'
      billingCycle: 1month
      classify: gpuserver
      zone: cn-hangzhou-b
      productForm: instance
      paymentRatio: '0'
      hpnZone: B1
      serverArch: bmserver
      computingServer: efg1.nvga1n
      stageNum: '36'
      renewalStatus: AutoRenewal
      renewPeriod: '36'
      status: Unused
  defaultNodeGroup:
    type: alicloud:eflo:NodeGroup
    name: default
    properties:
      nodes:
        - nodeId: ${defaultNode.id}
          vpcId: ${createVpc.id}
          vswitchId: ${createVswitch.id}
          hostname: jxyhostname
          loginPassword: Alibaba@2025
      ignoreFailedNodeTasks: 'true'
      clusterId: ${defaultCluster.id}
      imageId: i195048661660874208657
      zoneId: cn-hangzhou-b
      vpdSubnets:
        - example
      userData: YWxpLGFsaSxhbGliYWJh
      vswitchZoneId: cn-hangzhou-b
      ipAllocationPolicies:
        - bondPolicy:
            bondDefaultSubnet: example
            bonds:
              - name: example
                subnet: example
          machineTypePolicies:
            - bonds:
                - name: example
                  subnet: example
              machineType: example
          nodePolicies:
            - nodeId: ${defaultNode.id}
              bonds:
                - name: example
                  subnet: example
      machineType: efg1.nvga1
      az: cn-hangzhou-b
      nodeGroupDescription: resource-example1
      nodeGroupName: tfacceflo63657_update
variables:
  default:
    fn::invoke:
      function: alicloud:resourcemanager:getResourceGroups
      arguments: {}
Copy

Create NodeGroup Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new NodeGroup(name: string, args: NodeGroupArgs, opts?: CustomResourceOptions);
@overload
def NodeGroup(resource_name: str,
              args: NodeGroupArgs,
              opts: Optional[ResourceOptions] = None)

@overload
def NodeGroup(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              machine_type: Optional[str] = None,
              cluster_id: Optional[str] = None,
              node_group_name: Optional[str] = None,
              image_id: Optional[str] = None,
              az: Optional[str] = None,
              node_group_description: Optional[str] = None,
              ip_allocation_policies: Optional[Sequence[NodeGroupIpAllocationPolicyArgs]] = None,
              ignore_failed_node_tasks: Optional[bool] = None,
              nodes: Optional[Sequence[NodeGroupNodeArgs]] = None,
              user_data: Optional[str] = None,
              vpd_subnets: Optional[Sequence[str]] = None,
              vswitch_zone_id: Optional[str] = None,
              zone_id: Optional[str] = None)
func NewNodeGroup(ctx *Context, name string, args NodeGroupArgs, opts ...ResourceOption) (*NodeGroup, error)
public NodeGroup(string name, NodeGroupArgs args, CustomResourceOptions? opts = null)
public NodeGroup(String name, NodeGroupArgs args)
public NodeGroup(String name, NodeGroupArgs args, CustomResourceOptions options)
type: alicloud:eflo:NodeGroup
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args This property is required. NodeGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args This property is required. NodeGroupArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args This property is required. NodeGroupArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args This property is required. NodeGroupArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. NodeGroupArgs
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 nodeGroupResource = new AliCloud.Eflo.NodeGroup("nodeGroupResource", new()
{
    MachineType = "string",
    ClusterId = "string",
    NodeGroupName = "string",
    ImageId = "string",
    Az = "string",
    NodeGroupDescription = "string",
    IpAllocationPolicies = new[]
    {
        new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyArgs
        {
            BondPolicy = new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicyArgs
            {
                BondDefaultSubnet = "string",
                Bonds = new[]
                {
                    new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicyBondArgs
                    {
                        Name = "string",
                        Subnet = "string",
                    },
                },
            },
            MachineTypePolicies = new[]
            {
                new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyMachineTypePolicyArgs
                {
                    Bonds = new[]
                    {
                        new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs
                        {
                            Name = "string",
                            Subnet = "string",
                        },
                    },
                    MachineType = "string",
                },
            },
            NodePolicies = new[]
            {
                new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyNodePolicyArgs
                {
                    Bonds = new[]
                    {
                        new AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyNodePolicyBondArgs
                        {
                            Name = "string",
                            Subnet = "string",
                        },
                    },
                    NodeId = "string",
                },
            },
        },
    },
    IgnoreFailedNodeTasks = false,
    Nodes = new[]
    {
        new AliCloud.Eflo.Inputs.NodeGroupNodeArgs
        {
            Hostname = "string",
            LoginPassword = "string",
            NodeId = "string",
            VpcId = "string",
            VswitchId = "string",
        },
    },
    UserData = "string",
    VpdSubnets = new[]
    {
        "string",
    },
    VswitchZoneId = "string",
    ZoneId = "string",
});
Copy
example, err := eflo.NewNodeGroup(ctx, "nodeGroupResource", &eflo.NodeGroupArgs{
	MachineType:          pulumi.String("string"),
	ClusterId:            pulumi.String("string"),
	NodeGroupName:        pulumi.String("string"),
	ImageId:              pulumi.String("string"),
	Az:                   pulumi.String("string"),
	NodeGroupDescription: pulumi.String("string"),
	IpAllocationPolicies: eflo.NodeGroupIpAllocationPolicyArray{
		&eflo.NodeGroupIpAllocationPolicyArgs{
			BondPolicy: &eflo.NodeGroupIpAllocationPolicyBondPolicyArgs{
				BondDefaultSubnet: pulumi.String("string"),
				Bonds: eflo.NodeGroupIpAllocationPolicyBondPolicyBondArray{
					&eflo.NodeGroupIpAllocationPolicyBondPolicyBondArgs{
						Name:   pulumi.String("string"),
						Subnet: pulumi.String("string"),
					},
				},
			},
			MachineTypePolicies: eflo.NodeGroupIpAllocationPolicyMachineTypePolicyArray{
				&eflo.NodeGroupIpAllocationPolicyMachineTypePolicyArgs{
					Bonds: eflo.NodeGroupIpAllocationPolicyMachineTypePolicyBondArray{
						&eflo.NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs{
							Name:   pulumi.String("string"),
							Subnet: pulumi.String("string"),
						},
					},
					MachineType: pulumi.String("string"),
				},
			},
			NodePolicies: eflo.NodeGroupIpAllocationPolicyNodePolicyArray{
				&eflo.NodeGroupIpAllocationPolicyNodePolicyArgs{
					Bonds: eflo.NodeGroupIpAllocationPolicyNodePolicyBondArray{
						&eflo.NodeGroupIpAllocationPolicyNodePolicyBondArgs{
							Name:   pulumi.String("string"),
							Subnet: pulumi.String("string"),
						},
					},
					NodeId: pulumi.String("string"),
				},
			},
		},
	},
	IgnoreFailedNodeTasks: pulumi.Bool(false),
	Nodes: eflo.NodeGroupNodeArray{
		&eflo.NodeGroupNodeArgs{
			Hostname:      pulumi.String("string"),
			LoginPassword: pulumi.String("string"),
			NodeId:        pulumi.String("string"),
			VpcId:         pulumi.String("string"),
			VswitchId:     pulumi.String("string"),
		},
	},
	UserData: pulumi.String("string"),
	VpdSubnets: pulumi.StringArray{
		pulumi.String("string"),
	},
	VswitchZoneId: pulumi.String("string"),
	ZoneId:        pulumi.String("string"),
})
Copy
var nodeGroupResource = new NodeGroup("nodeGroupResource", NodeGroupArgs.builder()
    .machineType("string")
    .clusterId("string")
    .nodeGroupName("string")
    .imageId("string")
    .az("string")
    .nodeGroupDescription("string")
    .ipAllocationPolicies(NodeGroupIpAllocationPolicyArgs.builder()
        .bondPolicy(NodeGroupIpAllocationPolicyBondPolicyArgs.builder()
            .bondDefaultSubnet("string")
            .bonds(NodeGroupIpAllocationPolicyBondPolicyBondArgs.builder()
                .name("string")
                .subnet("string")
                .build())
            .build())
        .machineTypePolicies(NodeGroupIpAllocationPolicyMachineTypePolicyArgs.builder()
            .bonds(NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs.builder()
                .name("string")
                .subnet("string")
                .build())
            .machineType("string")
            .build())
        .nodePolicies(NodeGroupIpAllocationPolicyNodePolicyArgs.builder()
            .bonds(NodeGroupIpAllocationPolicyNodePolicyBondArgs.builder()
                .name("string")
                .subnet("string")
                .build())
            .nodeId("string")
            .build())
        .build())
    .ignoreFailedNodeTasks(false)
    .nodes(NodeGroupNodeArgs.builder()
        .hostname("string")
        .loginPassword("string")
        .nodeId("string")
        .vpcId("string")
        .vswitchId("string")
        .build())
    .userData("string")
    .vpdSubnets("string")
    .vswitchZoneId("string")
    .zoneId("string")
    .build());
Copy
node_group_resource = alicloud.eflo.NodeGroup("nodeGroupResource",
    machine_type="string",
    cluster_id="string",
    node_group_name="string",
    image_id="string",
    az="string",
    node_group_description="string",
    ip_allocation_policies=[{
        "bond_policy": {
            "bond_default_subnet": "string",
            "bonds": [{
                "name": "string",
                "subnet": "string",
            }],
        },
        "machine_type_policies": [{
            "bonds": [{
                "name": "string",
                "subnet": "string",
            }],
            "machine_type": "string",
        }],
        "node_policies": [{
            "bonds": [{
                "name": "string",
                "subnet": "string",
            }],
            "node_id": "string",
        }],
    }],
    ignore_failed_node_tasks=False,
    nodes=[{
        "hostname": "string",
        "login_password": "string",
        "node_id": "string",
        "vpc_id": "string",
        "vswitch_id": "string",
    }],
    user_data="string",
    vpd_subnets=["string"],
    vswitch_zone_id="string",
    zone_id="string")
Copy
const nodeGroupResource = new alicloud.eflo.NodeGroup("nodeGroupResource", {
    machineType: "string",
    clusterId: "string",
    nodeGroupName: "string",
    imageId: "string",
    az: "string",
    nodeGroupDescription: "string",
    ipAllocationPolicies: [{
        bondPolicy: {
            bondDefaultSubnet: "string",
            bonds: [{
                name: "string",
                subnet: "string",
            }],
        },
        machineTypePolicies: [{
            bonds: [{
                name: "string",
                subnet: "string",
            }],
            machineType: "string",
        }],
        nodePolicies: [{
            bonds: [{
                name: "string",
                subnet: "string",
            }],
            nodeId: "string",
        }],
    }],
    ignoreFailedNodeTasks: false,
    nodes: [{
        hostname: "string",
        loginPassword: "string",
        nodeId: "string",
        vpcId: "string",
        vswitchId: "string",
    }],
    userData: "string",
    vpdSubnets: ["string"],
    vswitchZoneId: "string",
    zoneId: "string",
});
Copy
type: alicloud:eflo:NodeGroup
properties:
    az: string
    clusterId: string
    ignoreFailedNodeTasks: false
    imageId: string
    ipAllocationPolicies:
        - bondPolicy:
            bondDefaultSubnet: string
            bonds:
                - name: string
                  subnet: string
          machineTypePolicies:
            - bonds:
                - name: string
                  subnet: string
              machineType: string
          nodePolicies:
            - bonds:
                - name: string
                  subnet: string
              nodeId: string
    machineType: string
    nodeGroupDescription: string
    nodeGroupName: string
    nodes:
        - hostname: string
          loginPassword: string
          nodeId: string
          vpcId: string
          vswitchId: string
    userData: string
    vpdSubnets:
        - string
    vswitchZoneId: string
    zoneId: string
Copy

NodeGroup Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The NodeGroup resource accepts the following input properties:

Az
This property is required.
Changes to this property will trigger replacement.
string
Az
ClusterId
This property is required.
Changes to this property will trigger replacement.
string
Cluster ID
ImageId
This property is required.
Changes to this property will trigger replacement.
string
Image ID
MachineType
This property is required.
Changes to this property will trigger replacement.
string
Machine type
NodeGroupName This property is required. string
The name of the resource
IgnoreFailedNodeTasks bool
Whether to allow skipping failed nodes. Default value: False
IpAllocationPolicies List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicy>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
NodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
Nodes List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupNode>
Node List See nodes below.
UserData string
Custom Data
VpdSubnets List<string>
Cluster subnet list
VswitchZoneId string
Zone ID of the switch
ZoneId string
Zone ID
Az
This property is required.
Changes to this property will trigger replacement.
string
Az
ClusterId
This property is required.
Changes to this property will trigger replacement.
string
Cluster ID
ImageId
This property is required.
Changes to this property will trigger replacement.
string
Image ID
MachineType
This property is required.
Changes to this property will trigger replacement.
string
Machine type
NodeGroupName This property is required. string
The name of the resource
IgnoreFailedNodeTasks bool
Whether to allow skipping failed nodes. Default value: False
IpAllocationPolicies []NodeGroupIpAllocationPolicyArgs
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
NodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
Nodes []NodeGroupNodeArgs
Node List See nodes below.
UserData string
Custom Data
VpdSubnets []string
Cluster subnet list
VswitchZoneId string
Zone ID of the switch
ZoneId string
Zone ID
az
This property is required.
Changes to this property will trigger replacement.
String
Az
clusterId
This property is required.
Changes to this property will trigger replacement.
String
Cluster ID
imageId
This property is required.
Changes to this property will trigger replacement.
String
Image ID
machineType
This property is required.
Changes to this property will trigger replacement.
String
Machine type
nodeGroupName This property is required. String
The name of the resource
ignoreFailedNodeTasks Boolean
Whether to allow skipping failed nodes. Default value: False
ipAllocationPolicies List<NodeGroupIpAllocationPolicy>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
nodeGroupDescription Changes to this property will trigger replacement. String
NodeGroupDescription
nodes List<NodeGroupNode>
Node List See nodes below.
userData String
Custom Data
vpdSubnets List<String>
Cluster subnet list
vswitchZoneId String
Zone ID of the switch
zoneId String
Zone ID
az
This property is required.
Changes to this property will trigger replacement.
string
Az
clusterId
This property is required.
Changes to this property will trigger replacement.
string
Cluster ID
imageId
This property is required.
Changes to this property will trigger replacement.
string
Image ID
machineType
This property is required.
Changes to this property will trigger replacement.
string
Machine type
nodeGroupName This property is required. string
The name of the resource
ignoreFailedNodeTasks boolean
Whether to allow skipping failed nodes. Default value: False
ipAllocationPolicies NodeGroupIpAllocationPolicy[]
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
nodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
nodes NodeGroupNode[]
Node List See nodes below.
userData string
Custom Data
vpdSubnets string[]
Cluster subnet list
vswitchZoneId string
Zone ID of the switch
zoneId string
Zone ID
az
This property is required.
Changes to this property will trigger replacement.
str
Az
cluster_id
This property is required.
Changes to this property will trigger replacement.
str
Cluster ID
image_id
This property is required.
Changes to this property will trigger replacement.
str
Image ID
machine_type
This property is required.
Changes to this property will trigger replacement.
str
Machine type
node_group_name This property is required. str
The name of the resource
ignore_failed_node_tasks bool
Whether to allow skipping failed nodes. Default value: False
ip_allocation_policies Sequence[NodeGroupIpAllocationPolicyArgs]
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
node_group_description Changes to this property will trigger replacement. str
NodeGroupDescription
nodes Sequence[NodeGroupNodeArgs]
Node List See nodes below.
user_data str
Custom Data
vpd_subnets Sequence[str]
Cluster subnet list
vswitch_zone_id str
Zone ID of the switch
zone_id str
Zone ID
az
This property is required.
Changes to this property will trigger replacement.
String
Az
clusterId
This property is required.
Changes to this property will trigger replacement.
String
Cluster ID
imageId
This property is required.
Changes to this property will trigger replacement.
String
Image ID
machineType
This property is required.
Changes to this property will trigger replacement.
String
Machine type
nodeGroupName This property is required. String
The name of the resource
ignoreFailedNodeTasks Boolean
Whether to allow skipping failed nodes. Default value: False
ipAllocationPolicies List<Property Map>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
nodeGroupDescription Changes to this property will trigger replacement. String
NodeGroupDescription
nodes List<Property Map>
Node List See nodes below.
userData String
Custom Data
vpdSubnets List<String>
Cluster subnet list
vswitchZoneId String
Zone ID of the switch
zoneId String
Zone ID

Outputs

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

CreateTime string
Create time
Id string
The provider-assigned unique ID for this managed resource.
NodeGroupId string
The first ID of the resource
CreateTime string
Create time
Id string
The provider-assigned unique ID for this managed resource.
NodeGroupId string
The first ID of the resource
createTime String
Create time
id String
The provider-assigned unique ID for this managed resource.
nodeGroupId String
The first ID of the resource
createTime string
Create time
id string
The provider-assigned unique ID for this managed resource.
nodeGroupId string
The first ID of the resource
create_time str
Create time
id str
The provider-assigned unique ID for this managed resource.
node_group_id str
The first ID of the resource
createTime String
Create time
id String
The provider-assigned unique ID for this managed resource.
nodeGroupId String
The first ID of the resource

Look up Existing NodeGroup Resource

Get an existing NodeGroup 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?: NodeGroupState, opts?: CustomResourceOptions): NodeGroup
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        az: Optional[str] = None,
        cluster_id: Optional[str] = None,
        create_time: Optional[str] = None,
        ignore_failed_node_tasks: Optional[bool] = None,
        image_id: Optional[str] = None,
        ip_allocation_policies: Optional[Sequence[NodeGroupIpAllocationPolicyArgs]] = None,
        machine_type: Optional[str] = None,
        node_group_description: Optional[str] = None,
        node_group_id: Optional[str] = None,
        node_group_name: Optional[str] = None,
        nodes: Optional[Sequence[NodeGroupNodeArgs]] = None,
        user_data: Optional[str] = None,
        vpd_subnets: Optional[Sequence[str]] = None,
        vswitch_zone_id: Optional[str] = None,
        zone_id: Optional[str] = None) -> NodeGroup
func GetNodeGroup(ctx *Context, name string, id IDInput, state *NodeGroupState, opts ...ResourceOption) (*NodeGroup, error)
public static NodeGroup Get(string name, Input<string> id, NodeGroupState? state, CustomResourceOptions? opts = null)
public static NodeGroup get(String name, Output<String> id, NodeGroupState state, CustomResourceOptions options)
resources:  _:    type: alicloud:eflo:NodeGroup    get:      id: ${id}
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
The unique provider ID of the resource to lookup.
name This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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 This property is required.
The unique name of the resulting resource.
id This property is required.
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:
Az Changes to this property will trigger replacement. string
Az
ClusterId Changes to this property will trigger replacement. string
Cluster ID
CreateTime string
Create time
IgnoreFailedNodeTasks bool
Whether to allow skipping failed nodes. Default value: False
ImageId Changes to this property will trigger replacement. string
Image ID
IpAllocationPolicies List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicy>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
MachineType Changes to this property will trigger replacement. string
Machine type
NodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
NodeGroupId string
The first ID of the resource
NodeGroupName string
The name of the resource
Nodes List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupNode>
Node List See nodes below.
UserData string
Custom Data
VpdSubnets List<string>
Cluster subnet list
VswitchZoneId string
Zone ID of the switch
ZoneId string
Zone ID
Az Changes to this property will trigger replacement. string
Az
ClusterId Changes to this property will trigger replacement. string
Cluster ID
CreateTime string
Create time
IgnoreFailedNodeTasks bool
Whether to allow skipping failed nodes. Default value: False
ImageId Changes to this property will trigger replacement. string
Image ID
IpAllocationPolicies []NodeGroupIpAllocationPolicyArgs
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
MachineType Changes to this property will trigger replacement. string
Machine type
NodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
NodeGroupId string
The first ID of the resource
NodeGroupName string
The name of the resource
Nodes []NodeGroupNodeArgs
Node List See nodes below.
UserData string
Custom Data
VpdSubnets []string
Cluster subnet list
VswitchZoneId string
Zone ID of the switch
ZoneId string
Zone ID
az Changes to this property will trigger replacement. String
Az
clusterId Changes to this property will trigger replacement. String
Cluster ID
createTime String
Create time
ignoreFailedNodeTasks Boolean
Whether to allow skipping failed nodes. Default value: False
imageId Changes to this property will trigger replacement. String
Image ID
ipAllocationPolicies List<NodeGroupIpAllocationPolicy>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
machineType Changes to this property will trigger replacement. String
Machine type
nodeGroupDescription Changes to this property will trigger replacement. String
NodeGroupDescription
nodeGroupId String
The first ID of the resource
nodeGroupName String
The name of the resource
nodes List<NodeGroupNode>
Node List See nodes below.
userData String
Custom Data
vpdSubnets List<String>
Cluster subnet list
vswitchZoneId String
Zone ID of the switch
zoneId String
Zone ID
az Changes to this property will trigger replacement. string
Az
clusterId Changes to this property will trigger replacement. string
Cluster ID
createTime string
Create time
ignoreFailedNodeTasks boolean
Whether to allow skipping failed nodes. Default value: False
imageId Changes to this property will trigger replacement. string
Image ID
ipAllocationPolicies NodeGroupIpAllocationPolicy[]
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
machineType Changes to this property will trigger replacement. string
Machine type
nodeGroupDescription Changes to this property will trigger replacement. string
NodeGroupDescription
nodeGroupId string
The first ID of the resource
nodeGroupName string
The name of the resource
nodes NodeGroupNode[]
Node List See nodes below.
userData string
Custom Data
vpdSubnets string[]
Cluster subnet list
vswitchZoneId string
Zone ID of the switch
zoneId string
Zone ID
az Changes to this property will trigger replacement. str
Az
cluster_id Changes to this property will trigger replacement. str
Cluster ID
create_time str
Create time
ignore_failed_node_tasks bool
Whether to allow skipping failed nodes. Default value: False
image_id Changes to this property will trigger replacement. str
Image ID
ip_allocation_policies Sequence[NodeGroupIpAllocationPolicyArgs]
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
machine_type Changes to this property will trigger replacement. str
Machine type
node_group_description Changes to this property will trigger replacement. str
NodeGroupDescription
node_group_id str
The first ID of the resource
node_group_name str
The name of the resource
nodes Sequence[NodeGroupNodeArgs]
Node List See nodes below.
user_data str
Custom Data
vpd_subnets Sequence[str]
Cluster subnet list
vswitch_zone_id str
Zone ID of the switch
zone_id str
Zone ID
az Changes to this property will trigger replacement. String
Az
clusterId Changes to this property will trigger replacement. String
Cluster ID
createTime String
Create time
ignoreFailedNodeTasks Boolean
Whether to allow skipping failed nodes. Default value: False
imageId Changes to this property will trigger replacement. String
Image ID
ipAllocationPolicies List<Property Map>
IP address combination policy: only one policy type can be selected for each policy, and multiple policies can be combined. See ip_allocation_policy below.
machineType Changes to this property will trigger replacement. String
Machine type
nodeGroupDescription Changes to this property will trigger replacement. String
NodeGroupDescription
nodeGroupId String
The first ID of the resource
nodeGroupName String
The name of the resource
nodes List<Property Map>
Node List See nodes below.
userData String
Custom Data
vpdSubnets List<String>
Cluster subnet list
vswitchZoneId String
Zone ID of the switch
zoneId String
Zone ID

Supporting Types

NodeGroupIpAllocationPolicy
, NodeGroupIpAllocationPolicyArgs

BondPolicy Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicy
Specify the cluster subnet ID based on the bond name See bond_policy below.
MachineTypePolicies List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyMachineTypePolicy>
Model Assignment Policy See machine_type_policy below.
NodePolicies List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyNodePolicy>
Node allocation policy See node_policy below.
BondPolicy NodeGroupIpAllocationPolicyBondPolicy
Specify the cluster subnet ID based on the bond name See bond_policy below.
MachineTypePolicies []NodeGroupIpAllocationPolicyMachineTypePolicy
Model Assignment Policy See machine_type_policy below.
NodePolicies []NodeGroupIpAllocationPolicyNodePolicy
Node allocation policy See node_policy below.
bondPolicy NodeGroupIpAllocationPolicyBondPolicy
Specify the cluster subnet ID based on the bond name See bond_policy below.
machineTypePolicies List<NodeGroupIpAllocationPolicyMachineTypePolicy>
Model Assignment Policy See machine_type_policy below.
nodePolicies List<NodeGroupIpAllocationPolicyNodePolicy>
Node allocation policy See node_policy below.
bondPolicy NodeGroupIpAllocationPolicyBondPolicy
Specify the cluster subnet ID based on the bond name See bond_policy below.
machineTypePolicies NodeGroupIpAllocationPolicyMachineTypePolicy[]
Model Assignment Policy See machine_type_policy below.
nodePolicies NodeGroupIpAllocationPolicyNodePolicy[]
Node allocation policy See node_policy below.
bond_policy NodeGroupIpAllocationPolicyBondPolicy
Specify the cluster subnet ID based on the bond name See bond_policy below.
machine_type_policies Sequence[NodeGroupIpAllocationPolicyMachineTypePolicy]
Model Assignment Policy See machine_type_policy below.
node_policies Sequence[NodeGroupIpAllocationPolicyNodePolicy]
Node allocation policy See node_policy below.
bondPolicy Property Map
Specify the cluster subnet ID based on the bond name See bond_policy below.
machineTypePolicies List<Property Map>
Model Assignment Policy See machine_type_policy below.
nodePolicies List<Property Map>
Node allocation policy See node_policy below.

NodeGroupIpAllocationPolicyBondPolicy
, NodeGroupIpAllocationPolicyBondPolicyArgs

BondDefaultSubnet string
Default bond cluster subnet
Bonds List<Pulumi.AliCloud.Eflo.Inputs.NodeGroupIpAllocationPolicyBondPolicyBond>
Bond information See bonds below.
BondDefaultSubnet string
Default bond cluster subnet
Bonds []NodeGroupIpAllocationPolicyBondPolicyBond
Bond information See bonds below.
bondDefaultSubnet String
Default bond cluster subnet
bonds List<NodeGroupIpAllocationPolicyBondPolicyBond>
Bond information See bonds below.
bondDefaultSubnet string
Default bond cluster subnet
bonds NodeGroupIpAllocationPolicyBondPolicyBond[]
Bond information See bonds below.
bond_default_subnet str
Default bond cluster subnet
bonds Sequence[NodeGroupIpAllocationPolicyBondPolicyBond]
Bond information See bonds below.
bondDefaultSubnet String
Default bond cluster subnet
bonds List<Property Map>
Bond information See bonds below.

NodeGroupIpAllocationPolicyBondPolicyBond
, NodeGroupIpAllocationPolicyBondPolicyBondArgs

Name string
The bond name
Subnet string
IP source cluster subnet
Name string
The bond name
Subnet string
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet
name string
The bond name
subnet string
IP source cluster subnet
name str
The bond name
subnet str
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet

NodeGroupIpAllocationPolicyMachineTypePolicy
, NodeGroupIpAllocationPolicyMachineTypePolicyArgs

Bonds []NodeGroupIpAllocationPolicyMachineTypePolicyBond
Bond information See bonds below.
MachineType string
Machine type
bonds List<NodeGroupIpAllocationPolicyMachineTypePolicyBond>
Bond information See bonds below.
machineType String
Machine type
bonds NodeGroupIpAllocationPolicyMachineTypePolicyBond[]
Bond information See bonds below.
machineType string
Machine type
bonds Sequence[NodeGroupIpAllocationPolicyMachineTypePolicyBond]
Bond information See bonds below.
machine_type str
Machine type
bonds List<Property Map>
Bond information See bonds below.
machineType String
Machine type

NodeGroupIpAllocationPolicyMachineTypePolicyBond
, NodeGroupIpAllocationPolicyMachineTypePolicyBondArgs

Name string
The bond name
Subnet string
IP source cluster subnet
Name string
The bond name
Subnet string
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet
name string
The bond name
subnet string
IP source cluster subnet
name str
The bond name
subnet str
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet

NodeGroupIpAllocationPolicyNodePolicy
, NodeGroupIpAllocationPolicyNodePolicyArgs

Bonds []NodeGroupIpAllocationPolicyNodePolicyBond
Bond information See bonds below.
NodeId string
bonds List<NodeGroupIpAllocationPolicyNodePolicyBond>
Bond information See bonds below.
nodeId String
bonds NodeGroupIpAllocationPolicyNodePolicyBond[]
Bond information See bonds below.
nodeId string
bonds List<Property Map>
Bond information See bonds below.
nodeId String

NodeGroupIpAllocationPolicyNodePolicyBond
, NodeGroupIpAllocationPolicyNodePolicyBondArgs

Name string
The bond name
Subnet string
IP source cluster subnet
Name string
The bond name
Subnet string
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet
name string
The bond name
subnet string
IP source cluster subnet
name str
The bond name
subnet str
IP source cluster subnet
name String
The bond name
subnet String
IP source cluster subnet

NodeGroupNode
, NodeGroupNodeArgs

Hostname string
Host name
LoginPassword string
Login Password
NodeId string
Node ID
VpcId string
VPC ID
VswitchId string
Switch ID
Hostname string
Host name
LoginPassword string
Login Password
NodeId string
Node ID
VpcId string
VPC ID
VswitchId string
Switch ID
hostname String
Host name
loginPassword String
Login Password
nodeId String
Node ID
vpcId String
VPC ID
vswitchId String
Switch ID
hostname string
Host name
loginPassword string
Login Password
nodeId string
Node ID
vpcId string
VPC ID
vswitchId string
Switch ID
hostname str
Host name
login_password str
Login Password
node_id str
Node ID
vpc_id str
VPC ID
vswitch_id str
Switch ID
hostname String
Host name
loginPassword String
Login Password
nodeId String
Node ID
vpcId String
VPC ID
vswitchId String
Switch ID

Import

Eflo Node Group can be imported using the id, e.g.

$ pulumi import alicloud:eflo/nodeGroup:NodeGroup example <cluster_id>:<node_group_id>
Copy

To learn more about importing existing cloud resources, see Importing resources.

Package Details

Repository
Alibaba Cloud pulumi/pulumi-alicloud
License
Apache-2.0
Notes
This Pulumi package is based on the alicloud Terraform Provider.