AclTokenArgs

data class AclTokenArgs(val expirationTtl: Output<String>? = null, val global: Output<Boolean>? = null, val name: Output<String>? = null, val policies: Output<List<String>>? = null, val roles: Output<List<AclTokenRoleArgs>>? = null, val type: Output<String>? = null) : ConvertibleToJava<AclTokenArgs>

Example Usage

Creating a token with limited policies:

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.nomad.AclToken;
import com.pulumi.nomad.AclTokenArgs;
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 dakota = new AclToken("dakota", AclTokenArgs.builder()
.policies(
"dev",
"qa")
.type("client")
.build());
}
}

Constructors

Link copied to clipboard
constructor(expirationTtl: Output<String>? = null, global: Output<Boolean>? = null, name: Output<String>? = null, policies: Output<List<String>>? = null, roles: Output<List<AclTokenRoleArgs>>? = null, type: Output<String>? = null)

Properties

Link copied to clipboard
val expirationTtl: Output<String>? = null

(string: "") - Provides a TTL for the token in the form of a time duration such as "5m" or "1h".

Link copied to clipboard
val global: Output<Boolean>? = null

(bool: false) - Whether the token should be replicated to all regions, or if it will only be used in the region it was created in.

Link copied to clipboard
val name: Output<String>? = null

(string: "") - A human-friendly name for this token.

Link copied to clipboard
val policies: Output<List<String>>? = null

(set: []) - A set of policy names to associate with this token. Must be set on client-type tokens, must not be set on management-type tokens. Policies do not need to exist before being used here.

Link copied to clipboard
val roles: Output<List<AclTokenRoleArgs>>? = null

(set: []) - The list of roles attached to the token. Each entry has name and id attributes. It may be used multiple times.

Link copied to clipboard
val type: Output<String>? = null

(string: <required>) - The type of token this is. Use client for tokens that will have policies associated with them. Use management for tokens that can perform any action.

Functions

Link copied to clipboard
open override fun toJava(): AclTokenArgs