1. Packages
  2. Proxmox Virtual Environment (Proxmox VE)
  3. API Docs
  4. Permission
  5. getRole
Proxmox Virtual Environment (Proxmox VE) v6.14.0 published on Monday, Sep 9, 2024 by Daniel Muehlbachler-Pietrzykowski

proxmoxve.Permission.getRole

Explore with Pulumi AI

proxmoxve logo
Proxmox Virtual Environment (Proxmox VE) v6.14.0 published on Monday, Sep 9, 2024 by Daniel Muehlbachler-Pietrzykowski

    Retrieves information about a specific role.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as proxmoxve from "@pulumi/proxmoxve";
    
    const operationsRole = proxmoxve.Permission.getRole({
        roleId: "operations",
    });
    
    import pulumi
    import pulumi_proxmoxve as proxmoxve
    
    operations_role = proxmoxve.Permission.get_role(role_id="operations")
    
    package main
    
    import (
    	"github.com/muhlba91/pulumi-proxmoxve/sdk/v6/go/proxmoxve/Permission"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Permission.GetRole(ctx, &permission.GetRoleArgs{
    			RoleId: "operations",
    		}, nil)
    		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 operationsRole = ProxmoxVE.Permission.GetRole.Invoke(new()
        {
            RoleId = "operations",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.proxmoxve.Permission.PermissionFunctions;
    import com.pulumi.proxmoxve.Permission.inputs.GetRoleArgs;
    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 operationsRole = PermissionFunctions.getRole(GetRoleArgs.builder()
                .roleId("operations")
                .build());
    
        }
    }
    
    variables:
      operationsRole:
        fn::invoke:
          Function: proxmoxve:Permission:getRole
          Arguments:
            roleId: operations
    

    Using getRole

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getRole(args: GetRoleArgs, opts?: InvokeOptions): Promise<GetRoleResult>
    function getRoleOutput(args: GetRoleOutputArgs, opts?: InvokeOptions): Output<GetRoleResult>
    def get_role(role_id: Optional[str] = None,
                 opts: Optional[InvokeOptions] = None) -> GetRoleResult
    def get_role_output(role_id: Optional[pulumi.Input[str]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[GetRoleResult]
    func GetRole(ctx *Context, args *GetRoleArgs, opts ...InvokeOption) (*GetRoleResult, error)
    func GetRoleOutput(ctx *Context, args *GetRoleOutputArgs, opts ...InvokeOption) GetRoleResultOutput

    > Note: This function is named GetRole in the Go SDK.

    public static class GetRole 
    {
        public static Task<GetRoleResult> InvokeAsync(GetRoleArgs args, InvokeOptions? opts = null)
        public static Output<GetRoleResult> Invoke(GetRoleInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetRoleResult> getRole(GetRoleArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: proxmoxve:Permission/getRole:getRole
      arguments:
        # arguments dictionary

    The following arguments are supported:

    RoleId string
    The role identifier.
    RoleId string
    The role identifier.
    roleId String
    The role identifier.
    roleId string
    The role identifier.
    role_id str
    The role identifier.
    roleId String
    The role identifier.

    getRole Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    Privileges List<string>
    The role privileges
    RoleId string
    Id string
    The provider-assigned unique ID for this managed resource.
    Privileges []string
    The role privileges
    RoleId string
    id String
    The provider-assigned unique ID for this managed resource.
    privileges List<String>
    The role privileges
    roleId String
    id string
    The provider-assigned unique ID for this managed resource.
    privileges string[]
    The role privileges
    roleId string
    id str
    The provider-assigned unique ID for this managed resource.
    privileges Sequence[str]
    The role privileges
    role_id str
    id String
    The provider-assigned unique ID for this managed resource.
    privileges List<String>
    The role privileges
    roleId String

    Package Details

    Repository
    proxmoxve muhlba91/pulumi-proxmoxve
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the proxmox Terraform Provider.
    proxmoxve logo
    Proxmox Virtual Environment (Proxmox VE) v6.14.0 published on Monday, Sep 9, 2024 by Daniel Muehlbachler-Pietrzykowski