1. Packages
  2. Packages
  3. Proxmox Virtual Environment (Proxmox VE)
  4. API Docs
  5. RoleLegacy
Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.1.0
published on Sunday, Apr 26, 2026 by Daniel Muehlbachler-Pietrzykowski
proxmoxve logo
Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.1.0
published on Sunday, Apr 26, 2026 by Daniel Muehlbachler-Pietrzykowski

    Manages a role.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as proxmoxve from "@muhlba91/pulumi-proxmoxve";
    
    const operationsMonitoring = new proxmoxve.RoleLegacy("operations_monitoring", {
        roleId: "operations-monitoring",
        privileges: ["VM.GuestAgent.Audit"],
    });
    
    import pulumi
    import pulumi_proxmoxve as proxmoxve
    
    operations_monitoring = proxmoxve.RoleLegacy("operations_monitoring",
        role_id="operations-monitoring",
        privileges=["VM.GuestAgent.Audit"])
    
    package main
    
    import (
    	"github.com/muhlba91/pulumi-proxmoxve/sdk/v8/go/proxmoxve"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := proxmoxve.NewRoleLegacy(ctx, "operations_monitoring", &proxmoxve.RoleLegacyArgs{
    			RoleId: pulumi.String("operations-monitoring"),
    			Privileges: pulumi.StringArray{
    				pulumi.String("VM.GuestAgent.Audit"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using ProxmoxVE = Pulumi.ProxmoxVE;
    
    return await Deployment.RunAsync(() => 
    {
        var operationsMonitoring = new ProxmoxVE.Index.RoleLegacy("operations_monitoring", new()
        {
            RoleId = "operations-monitoring",
            Privileges = new[]
            {
                "VM.GuestAgent.Audit",
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import io.muehlbachler.pulumi.proxmoxve.RoleLegacy;
    import io.muehlbachler.pulumi.proxmoxve.RoleLegacyArgs;
    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) {
            var operationsMonitoring = new RoleLegacy("operationsMonitoring", RoleLegacyArgs.builder()
                .roleId("operations-monitoring")
                .privileges("VM.GuestAgent.Audit")
                .build());
    
        }
    }
    
    resources:
      operationsMonitoring:
        type: proxmoxve:RoleLegacy
        name: operations_monitoring
        properties:
          roleId: operations-monitoring
          privileges:
            - VM.GuestAgent.Audit
    
    Example coming soon!
    

    Create RoleLegacy Resource

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

    Constructor syntax

    new RoleLegacy(name: string, args: RoleLegacyArgs, opts?: CustomResourceOptions);
    @overload
    def RoleLegacy(resource_name: str,
                   args: RoleLegacyArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def RoleLegacy(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   privileges: Optional[Sequence[str]] = None,
                   role_id: Optional[str] = None)
    func NewRoleLegacy(ctx *Context, name string, args RoleLegacyArgs, opts ...ResourceOption) (*RoleLegacy, error)
    public RoleLegacy(string name, RoleLegacyArgs args, CustomResourceOptions? opts = null)
    public RoleLegacy(String name, RoleLegacyArgs args)
    public RoleLegacy(String name, RoleLegacyArgs args, CustomResourceOptions options)
    
    type: proxmoxve:RoleLegacy
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    
    resource "proxmoxve_rolelegacy" "name" {
        # resource properties
    }

    Parameters

    name string
    The unique name of the resource.
    args RoleLegacyArgs
    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 RoleLegacyArgs
    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 RoleLegacyArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args RoleLegacyArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args RoleLegacyArgs
    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 roleLegacyResource = new ProxmoxVE.RoleLegacy("roleLegacyResource", new()
    {
        Privileges = new[]
        {
            "string",
        },
        RoleId = "string",
    });
    
    example, err := proxmoxve.NewRoleLegacy(ctx, "roleLegacyResource", &proxmoxve.RoleLegacyArgs{
    	Privileges: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	RoleId: pulumi.String("string"),
    })
    
    resource "proxmoxve_rolelegacy" "roleLegacyResource" {
      privileges = ["string"]
      role_id    = "string"
    }
    
    var roleLegacyResource = new RoleLegacy("roleLegacyResource", RoleLegacyArgs.builder()
        .privileges("string")
        .roleId("string")
        .build());
    
    role_legacy_resource = proxmoxve.RoleLegacy("roleLegacyResource",
        privileges=["string"],
        role_id="string")
    
    const roleLegacyResource = new proxmoxve.RoleLegacy("roleLegacyResource", {
        privileges: ["string"],
        roleId: "string",
    });
    
    type: proxmoxve:RoleLegacy
    properties:
        privileges:
            - string
        roleId: string
    

    RoleLegacy 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 RoleLegacy resource accepts the following input properties:

    Privileges List<string>
    The role privileges.
    RoleId string
    The role identifier.
    Privileges []string
    The role privileges.
    RoleId string
    The role identifier.
    privileges list(string)
    The role privileges.
    role_id string
    The role identifier.
    privileges List<String>
    The role privileges.
    roleId String
    The role identifier.
    privileges string[]
    The role privileges.
    roleId string
    The role identifier.
    privileges Sequence[str]
    The role privileges.
    role_id str
    The role identifier.
    privileges List<String>
    The role privileges.
    roleId String
    The role identifier.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing RoleLegacy Resource

    Get an existing RoleLegacy 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?: RoleLegacyState, opts?: CustomResourceOptions): RoleLegacy
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            privileges: Optional[Sequence[str]] = None,
            role_id: Optional[str] = None) -> RoleLegacy
    func GetRoleLegacy(ctx *Context, name string, id IDInput, state *RoleLegacyState, opts ...ResourceOption) (*RoleLegacy, error)
    public static RoleLegacy Get(string name, Input<string> id, RoleLegacyState? state, CustomResourceOptions? opts = null)
    public static RoleLegacy get(String name, Output<String> id, RoleLegacyState state, CustomResourceOptions options)
    resources:  _:    type: proxmoxve:RoleLegacy    get:      id: ${id}
    import {
      to = proxmoxve_rolelegacy.example
      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.
    The following state arguments are supported:
    Privileges List<string>
    The role privileges.
    RoleId string
    The role identifier.
    Privileges []string
    The role privileges.
    RoleId string
    The role identifier.
    privileges list(string)
    The role privileges.
    role_id string
    The role identifier.
    privileges List<String>
    The role privileges.
    roleId String
    The role identifier.
    privileges string[]
    The role privileges.
    roleId string
    The role identifier.
    privileges Sequence[str]
    The role privileges.
    role_id str
    The role identifier.
    privileges List<String>
    The role privileges.
    roleId String
    The role identifier.

    Import

    Instances can be imported using the roleId, e.g.,

    $ pulumi import proxmoxve:index/roleLegacy:RoleLegacy operations_monitoring operations-monitoring
    

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

    Package Details

    Repository
    proxmoxve muhlba91/pulumi-proxmoxve
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the proxmox Terraform Provider.
    proxmoxve logo
    Viewing docs for Proxmox Virtual Environment (Proxmox VE) v8.1.0
    published on Sunday, Apr 26, 2026 by Daniel Muehlbachler-Pietrzykowski
      Try Pulumi Cloud free. Your team will thank you.