vault_nomad_secret_role

Creates a Vault role for a Nomad token. This role configures how generated tokens will function.

Example Usage

resource "vault_nomad_secret_backend" "config" {
  backend                   = "nomad"
  description               = "test description"
  default_lease_ttl_seconds = "3600"
  max_lease_ttl_seconds     = "7200"
  address                   = "https://127.0.0.1:4646"
  token                     = "ae20ceaa-..."
}

resource "vault_nomad_secret_role" "test" {
  backend   = vault_nomad_secret_backend.config.backend
  role      = "test"
  type      = "client"
  policies  = ["readonly"]
}

Argument Reference

The following arguments are supported:

Attributes Reference

No additional attributes are exported by this resource.

Import

Nomad secret role can be imported using the backend, e.g.

$ terraform import vault_nomad_secret_role.bob nomad/role/bob