hpegl.CaasMachineBlueprint
Explore with Pulumi AI
The machine blueprint resource facilitates the creation and deletion of a CaaS machine blueprint. Update is currently not supported. The required inputs when creating a cluster blueprint are name, site-id, machine_provider, machine_roles, compute_type, size and storage_type
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as hpegl from "@pulumi/hpegl";
const config = new pulumi.Config();
const hPEGLSPACE = config.require("hPEGLSPACE");
const blr = hpegl.getCaasSite({
    name: "BLR",
    spaceId: hPEGLSPACE,
});
const test = new hpegl.CaasMachineBlueprint("test", {
    siteId: blr.then(blr => blr.id),
    machineRoles: ["controlplane"],
    machineProvider: "vmaas",
    workerType: "",
    computeType: "",
    size: "",
    storageType: "",
});
import pulumi
import pulumi_hpegl as hpegl
config = pulumi.Config()
h_peglspace = config.require("hPEGLSPACE")
blr = hpegl.get_caas_site(name="BLR",
    space_id=h_peglspace)
test = hpegl.CaasMachineBlueprint("test",
    site_id=blr.id,
    machine_roles=["controlplane"],
    machine_provider="vmaas",
    worker_type="",
    compute_type="",
    size="",
    storage_type="")
package main
import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/hpegl/hpegl"
	"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, "")
		hPEGLSPACE := cfg.Require("hPEGLSPACE")
		blr, err := hpegl.GetCaasSite(ctx, &hpegl.GetCaasSiteArgs{
			Name:    "BLR",
			SpaceId: hPEGLSPACE,
		}, nil)
		if err != nil {
			return err
		}
		_, err = hpegl.NewCaasMachineBlueprint(ctx, "test", &hpegl.CaasMachineBlueprintArgs{
			SiteId: pulumi.String(blr.Id),
			MachineRoles: pulumi.StringArray{
				pulumi.String("controlplane"),
			},
			MachineProvider: pulumi.String("vmaas"),
			WorkerType:      pulumi.String(""),
			ComputeType:     pulumi.String(""),
			Size:            pulumi.String(""),
			StorageType:     pulumi.String(""),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Hpegl = Pulumi.Hpegl;
return await Deployment.RunAsync(() => 
{
    var config = new Config();
    var hPEGLSPACE = config.Require("hPEGLSPACE");
    var blr = Hpegl.GetCaasSite.Invoke(new()
    {
        Name = "BLR",
        SpaceId = hPEGLSPACE,
    });
    var test = new Hpegl.CaasMachineBlueprint("test", new()
    {
        SiteId = blr.Apply(getCaasSiteResult => getCaasSiteResult.Id),
        MachineRoles = new[]
        {
            "controlplane",
        },
        MachineProvider = "vmaas",
        WorkerType = "",
        ComputeType = "",
        Size = "",
        StorageType = "",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.hpegl.HpeglFunctions;
import com.pulumi.hpegl.inputs.GetCaasSiteArgs;
import com.pulumi.hpegl.CaasMachineBlueprint;
import com.pulumi.hpegl.CaasMachineBlueprintArgs;
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 hPEGLSPACE = config.get("hPEGLSPACE");
        final var blr = HpeglFunctions.getCaasSite(GetCaasSiteArgs.builder()
            .name("BLR")
            .spaceId(hPEGLSPACE)
            .build());
        var test = new CaasMachineBlueprint("test", CaasMachineBlueprintArgs.builder()
            .siteId(blr.applyValue(getCaasSiteResult -> getCaasSiteResult.id()))
            .machineRoles("controlplane")
            .machineProvider("vmaas")
            .workerType("")
            .computeType("")
            .size("")
            .storageType("")
            .build());
    }
}
configuration:
  hPEGLSPACE:
    type: string
resources:
  test:
    type: hpegl:CaasMachineBlueprint
    properties:
      siteId: ${blr.id}
      machineRoles:
        - controlplane
      machineProvider: vmaas
      workerType: ""
      computeType: ""
      size: ""
      storageType: ""
variables:
  blr:
    fn::invoke:
      function: hpegl:getCaasSite
      arguments:
        name: BLR
        spaceId: ${hPEGLSPACE}
Create CaasMachineBlueprint Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new CaasMachineBlueprint(name: string, args: CaasMachineBlueprintArgs, opts?: CustomResourceOptions);@overload
def CaasMachineBlueprint(resource_name: str,
                         args: CaasMachineBlueprintArgs,
                         opts: Optional[ResourceOptions] = None)
@overload
def CaasMachineBlueprint(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         compute_type: Optional[str] = None,
                         machine_provider: Optional[str] = None,
                         machine_roles: Optional[Sequence[str]] = None,
                         site_id: Optional[str] = None,
                         size: Optional[str] = None,
                         storage_type: Optional[str] = None,
                         worker_type: Optional[str] = None,
                         caas_machine_blueprint_id: Optional[str] = None,
                         name: Optional[str] = None)func NewCaasMachineBlueprint(ctx *Context, name string, args CaasMachineBlueprintArgs, opts ...ResourceOption) (*CaasMachineBlueprint, error)public CaasMachineBlueprint(string name, CaasMachineBlueprintArgs args, CustomResourceOptions? opts = null)
public CaasMachineBlueprint(String name, CaasMachineBlueprintArgs args)
public CaasMachineBlueprint(String name, CaasMachineBlueprintArgs args, CustomResourceOptions options)
type: hpegl:CaasMachineBlueprint
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 CaasMachineBlueprintArgs
- 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 CaasMachineBlueprintArgs
- 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 CaasMachineBlueprintArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args CaasMachineBlueprintArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args CaasMachineBlueprintArgs
- 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 caasMachineBlueprintResource = new Hpegl.CaasMachineBlueprint("caasMachineBlueprintResource", new()
{
    ComputeType = "string",
    MachineProvider = "string",
    MachineRoles = new[]
    {
        "string",
    },
    SiteId = "string",
    Size = "string",
    StorageType = "string",
    WorkerType = "string",
    CaasMachineBlueprintId = "string",
    Name = "string",
});
example, err := hpegl.NewCaasMachineBlueprint(ctx, "caasMachineBlueprintResource", &hpegl.CaasMachineBlueprintArgs{
	ComputeType:     pulumi.String("string"),
	MachineProvider: pulumi.String("string"),
	MachineRoles: pulumi.StringArray{
		pulumi.String("string"),
	},
	SiteId:                 pulumi.String("string"),
	Size:                   pulumi.String("string"),
	StorageType:            pulumi.String("string"),
	WorkerType:             pulumi.String("string"),
	CaasMachineBlueprintId: pulumi.String("string"),
	Name:                   pulumi.String("string"),
})
var caasMachineBlueprintResource = new CaasMachineBlueprint("caasMachineBlueprintResource", CaasMachineBlueprintArgs.builder()
    .computeType("string")
    .machineProvider("string")
    .machineRoles("string")
    .siteId("string")
    .size("string")
    .storageType("string")
    .workerType("string")
    .caasMachineBlueprintId("string")
    .name("string")
    .build());
caas_machine_blueprint_resource = hpegl.CaasMachineBlueprint("caasMachineBlueprintResource",
    compute_type="string",
    machine_provider="string",
    machine_roles=["string"],
    site_id="string",
    size="string",
    storage_type="string",
    worker_type="string",
    caas_machine_blueprint_id="string",
    name="string")
const caasMachineBlueprintResource = new hpegl.CaasMachineBlueprint("caasMachineBlueprintResource", {
    computeType: "string",
    machineProvider: "string",
    machineRoles: ["string"],
    siteId: "string",
    size: "string",
    storageType: "string",
    workerType: "string",
    caasMachineBlueprintId: "string",
    name: "string",
});
type: hpegl:CaasMachineBlueprint
properties:
    caasMachineBlueprintId: string
    computeType: string
    machineProvider: string
    machineRoles:
        - string
    name: string
    siteId: string
    size: string
    storageType: string
    workerType: string
CaasMachineBlueprint 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 CaasMachineBlueprint resource accepts the following input properties:
- ComputeType string
- MachineProvider string
- MachineRoles List<string>
- SiteId string
- Size string
- StorageType string
- WorkerType string
- CaasMachine stringBlueprint Id 
- The ID of this resource.
- Name string
- ComputeType string
- MachineProvider string
- MachineRoles []string
- SiteId string
- Size string
- StorageType string
- WorkerType string
- CaasMachine stringBlueprint Id 
- The ID of this resource.
- Name string
- computeType String
- machineProvider String
- machineRoles List<String>
- siteId String
- size String
- storageType String
- workerType String
- caasMachine StringBlueprint Id 
- The ID of this resource.
- name String
- computeType string
- machineProvider string
- machineRoles string[]
- siteId string
- size string
- storageType string
- workerType string
- caasMachine stringBlueprint Id 
- The ID of this resource.
- name string
- compute_type str
- machine_provider str
- machine_roles Sequence[str]
- site_id str
- size str
- storage_type str
- worker_type str
- caas_machine_ strblueprint_ id 
- The ID of this resource.
- name str
- computeType String
- machineProvider String
- machineRoles List<String>
- siteId String
- size String
- storageType String
- workerType String
- caasMachine StringBlueprint Id 
- The ID of this resource.
- name String
Outputs
All input properties are implicitly available as output properties. Additionally, the CaasMachineBlueprint resource produces the following output properties:
- CreatedDate string
- Id string
- The provider-assigned unique ID for this managed resource.
- LastUpdate stringDate 
- SizeDetails List<CaasMachine Blueprint Size Detail> 
- CreatedDate string
- Id string
- The provider-assigned unique ID for this managed resource.
- LastUpdate stringDate 
- SizeDetails []CaasMachine Blueprint Size Detail 
- createdDate String
- id String
- The provider-assigned unique ID for this managed resource.
- lastUpdate StringDate 
- sizeDetails List<CaasMachine Blueprint Size Detail> 
- createdDate string
- id string
- The provider-assigned unique ID for this managed resource.
- lastUpdate stringDate 
- sizeDetails CaasMachine Blueprint Size Detail[] 
- created_date str
- id str
- The provider-assigned unique ID for this managed resource.
- last_update_ strdate 
- size_details Sequence[CaasMachine Blueprint Size Detail] 
- createdDate String
- id String
- The provider-assigned unique ID for this managed resource.
- lastUpdate StringDate 
- sizeDetails List<Property Map>
Look up Existing CaasMachineBlueprint Resource
Get an existing CaasMachineBlueprint 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?: CaasMachineBlueprintState, opts?: CustomResourceOptions): CaasMachineBlueprint@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        caas_machine_blueprint_id: Optional[str] = None,
        compute_type: Optional[str] = None,
        created_date: Optional[str] = None,
        last_update_date: Optional[str] = None,
        machine_provider: Optional[str] = None,
        machine_roles: Optional[Sequence[str]] = None,
        name: Optional[str] = None,
        site_id: Optional[str] = None,
        size: Optional[str] = None,
        size_details: Optional[Sequence[CaasMachineBlueprintSizeDetailArgs]] = None,
        storage_type: Optional[str] = None,
        worker_type: Optional[str] = None) -> CaasMachineBlueprintfunc GetCaasMachineBlueprint(ctx *Context, name string, id IDInput, state *CaasMachineBlueprintState, opts ...ResourceOption) (*CaasMachineBlueprint, error)public static CaasMachineBlueprint Get(string name, Input<string> id, CaasMachineBlueprintState? state, CustomResourceOptions? opts = null)public static CaasMachineBlueprint get(String name, Output<String> id, CaasMachineBlueprintState state, CustomResourceOptions options)resources:  _:    type: hpegl:CaasMachineBlueprint    get:      id: ${id}- 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.
- CaasMachine stringBlueprint Id 
- The ID of this resource.
- ComputeType string
- CreatedDate string
- LastUpdate stringDate 
- MachineProvider string
- MachineRoles List<string>
- Name string
- SiteId string
- Size string
- SizeDetails List<CaasMachine Blueprint Size Detail> 
- StorageType string
- WorkerType string
- CaasMachine stringBlueprint Id 
- The ID of this resource.
- ComputeType string
- CreatedDate string
- LastUpdate stringDate 
- MachineProvider string
- MachineRoles []string
- Name string
- SiteId string
- Size string
- SizeDetails []CaasMachine Blueprint Size Detail Args 
- StorageType string
- WorkerType string
- caasMachine StringBlueprint Id 
- The ID of this resource.
- computeType String
- createdDate String
- lastUpdate StringDate 
- machineProvider String
- machineRoles List<String>
- name String
- siteId String
- size String
- sizeDetails List<CaasMachine Blueprint Size Detail> 
- storageType String
- workerType String
- caasMachine stringBlueprint Id 
- The ID of this resource.
- computeType string
- createdDate string
- lastUpdate stringDate 
- machineProvider string
- machineRoles string[]
- name string
- siteId string
- size string
- sizeDetails CaasMachine Blueprint Size Detail[] 
- storageType string
- workerType string
- caas_machine_ strblueprint_ id 
- The ID of this resource.
- compute_type str
- created_date str
- last_update_ strdate 
- machine_provider str
- machine_roles Sequence[str]
- name str
- site_id str
- size str
- size_details Sequence[CaasMachine Blueprint Size Detail Args] 
- storage_type str
- worker_type str
- caasMachine StringBlueprint Id 
- The ID of this resource.
- computeType String
- createdDate String
- lastUpdate StringDate 
- machineProvider String
- machineRoles List<String>
- name String
- siteId String
- size String
- sizeDetails List<Property Map>
- storageType String
- workerType String
Supporting Types
CaasMachineBlueprintSizeDetail, CaasMachineBlueprintSizeDetailArgs          
- Cpu double
- EphemeralDisk double
- Memory double
- Name string
- PersistentDisk double
- RootDisk double
- Cpu float64
- EphemeralDisk float64
- Memory float64
- Name string
- PersistentDisk float64
- RootDisk float64
- cpu Double
- ephemeralDisk Double
- memory Double
- name String
- persistentDisk Double
- rootDisk Double
- cpu number
- ephemeralDisk number
- memory number
- name string
- persistentDisk number
- rootDisk number
- cpu float
- ephemeral_disk float
- memory float
- name str
- persistent_disk float
- root_disk float
- cpu Number
- ephemeralDisk Number
- memory Number
- name String
- persistentDisk Number
- rootDisk Number
Package Details
- Repository
- hpegl hpe/terraform-provider-hpegl
- License
- Notes
- This Pulumi package is based on the hpeglTerraform Provider.