HashiCorp Nomad

v0.3.0 published on Tuesday, Sep 27, 2022 by Pulumi

getAclToken

Example Usage

using System.Collections.Generic;
using Pulumi;
using Nomad = Pulumi.Nomad;

return await Deployment.RunAsync(() => 
{
    var myToken = Nomad.GetAclToken.Invoke(new()
    {
        AccessorId = "aa534e09-6a07-0a45-2295-a7f77063d429",
    });

});
package main

import (
	"github.com/pulumi/pulumi-nomad/sdk/go/nomad"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := nomad.LookupAclToken(ctx, &GetAclTokenArgs{
			AccessorId: "aa534e09-6a07-0a45-2295-a7f77063d429",
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.nomad.NomadFunctions;
import com.pulumi.nomad.inputs.GetAclTokenArgs;
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 myToken = NomadFunctions.getAclToken(GetAclTokenArgs.builder()
            .accessorId("aa534e09-6a07-0a45-2295-a7f77063d429")
            .build());

    }
}
import pulumi
import pulumi_nomad as nomad

my_token = nomad.get_acl_token(accessor_id="aa534e09-6a07-0a45-2295-a7f77063d429")
import * as pulumi from "@pulumi/pulumi";
import * as nomad from "@pulumi/nomad";

const myToken = pulumi.output(nomad.getAclToken({
    accessorId: "aa534e09-6a07-0a45-2295-a7f77063d429",
}));
variables:
  myToken:
    Fn::Invoke:
      Function: nomad:getAclToken
      Arguments:
        accessorId: aa534e09-6a07-0a45-2295-a7f77063d429

Using getAclToken

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 getAclToken(args: GetAclTokenArgs, opts?: InvokeOptions): Promise<GetAclTokenResult>
function getAclTokenOutput(args: GetAclTokenOutputArgs, opts?: InvokeOptions): Output<GetAclTokenResult>
def get_acl_token(accessor_id: Optional[str] = None,
                  opts: Optional[InvokeOptions] = None) -> GetAclTokenResult
def get_acl_token_output(accessor_id: Optional[pulumi.Input[str]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetAclTokenResult]
func LookupAclToken(ctx *Context, args *LookupAclTokenArgs, opts ...InvokeOption) (*LookupAclTokenResult, error)
func LookupAclTokenOutput(ctx *Context, args *LookupAclTokenOutputArgs, opts ...InvokeOption) LookupAclTokenResultOutput

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

public static class GetAclToken 
{
    public static Task<GetAclTokenResult> InvokeAsync(GetAclTokenArgs args, InvokeOptions? opts = null)
    public static Output<GetAclTokenResult> Invoke(GetAclTokenInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAclTokenResult> getAclToken(GetAclTokenArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: nomad:index/getAclToken:getAclToken
  Arguments:
    # Arguments dictionary

The following arguments are supported:

AccessorId string
AccessorId string
accessorId String
accessorId string
accessorId String

getAclToken Result

The following output properties are available:

AccessorId string
CreateTime string
Global bool
Id string

The provider-assigned unique ID for this managed resource.

Name string
Policies List<string>
SecretId string
Type string
AccessorId string
CreateTime string
Global bool
Id string

The provider-assigned unique ID for this managed resource.

Name string
Policies []string
SecretId string
Type string
accessorId String
createTime String
global Boolean
id String

The provider-assigned unique ID for this managed resource.

name String
policies List<String>
secretId String
type String
accessorId string
createTime string
global boolean
id string

The provider-assigned unique ID for this managed resource.

name string
policies string[]
secretId string
type string
accessor_id str
create_time str
global_ bool
id str

The provider-assigned unique ID for this managed resource.

name str
policies Sequence[str]
secret_id str
type str
accessorId String
createTime String
global Boolean
id String

The provider-assigned unique ID for this managed resource.

name String
policies List<String>
secretId String
type String

Package Details

Repository
https://github.com/pulumi/pulumi-nomad
License
Apache-2.0
Notes

This Pulumi package is based on the nomad Terraform Provider.