UNPKG

@muhlba91/pulumi-proxmoxve

Version:

A Pulumi package for creating and managing Proxmox Virtual Environment cloud resources.

150 lines (149 loc) 4.1 kB
import * as pulumi from "@pulumi/pulumi"; import * as inputs from "../types/input"; import * as outputs from "../types/output"; /** * Retrieves information about all VMs in the Proxmox cluster. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as proxmoxve from "@muhlba91/pulumi-proxmoxve"; * * const ubuntuVms = proxmoxve.VM.getVirtualMachines({ * tags: ["ubuntu"], * }); * const ubuntuTemplates = proxmoxve.VM.getVirtualMachines({ * filters: [ * { * name: "template", * values: ["true"], * }, * { * name: "status", * values: ["stopped"], * }, * { * name: "name", * regex: true, * values: ["^ubuntu-20.*$"], * }, * { * name: "node_name", * regex: true, * values: [ * "node_us_[1-3]", * "node_eu_[1-3]", * ], * }, * ], * tags: [ * "template", * "latest", * ], * }); * ``` */ export declare function getVirtualMachines(args?: GetVirtualMachinesArgs, opts?: pulumi.InvokeOptions): Promise<GetVirtualMachinesResult>; /** * A collection of arguments for invoking getVirtualMachines. */ export interface GetVirtualMachinesArgs { /** * Filter blocks. The VM must satisfy all filter blocks to be included in the result. */ filters?: inputs.VM.GetVirtualMachinesFilter[]; /** * The node name. All cluster nodes will be queried in case this is omitted */ nodeName?: string; /** * A list of tags to filter the VMs. The VM must have all * the tags to be included in the result. */ tags?: string[]; } /** * A collection of values returned by getVirtualMachines. */ export interface GetVirtualMachinesResult { readonly filters?: outputs.VM.GetVirtualMachinesFilter[]; /** * The provider-assigned unique ID for this managed resource. */ readonly id: string; /** * The node name. */ readonly nodeName?: string; /** * A list of tags of the VM. */ readonly tags?: string[]; /** * The VMs list. */ readonly vms: outputs.VM.GetVirtualMachinesVm[]; } /** * Retrieves information about all VMs in the Proxmox cluster. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as proxmoxve from "@muhlba91/pulumi-proxmoxve"; * * const ubuntuVms = proxmoxve.VM.getVirtualMachines({ * tags: ["ubuntu"], * }); * const ubuntuTemplates = proxmoxve.VM.getVirtualMachines({ * filters: [ * { * name: "template", * values: ["true"], * }, * { * name: "status", * values: ["stopped"], * }, * { * name: "name", * regex: true, * values: ["^ubuntu-20.*$"], * }, * { * name: "node_name", * regex: true, * values: [ * "node_us_[1-3]", * "node_eu_[1-3]", * ], * }, * ], * tags: [ * "template", * "latest", * ], * }); * ``` */ export declare function getVirtualMachinesOutput(args?: GetVirtualMachinesOutputArgs, opts?: pulumi.InvokeOutputOptions): pulumi.Output<GetVirtualMachinesResult>; /** * A collection of arguments for invoking getVirtualMachines. */ export interface GetVirtualMachinesOutputArgs { /** * Filter blocks. The VM must satisfy all filter blocks to be included in the result. */ filters?: pulumi.Input<pulumi.Input<inputs.VM.GetVirtualMachinesFilterArgs>[]>; /** * The node name. All cluster nodes will be queried in case this is omitted */ nodeName?: pulumi.Input<string>; /** * A list of tags to filter the VMs. The VM must have all * the tags to be included in the result. */ tags?: pulumi.Input<pulumi.Input<string>[]>; }