SecretBackend

class SecretBackend : KotlinCustomResource

Example Usage

Creating a standard backend resource:

import * as pulumi from "@pulumi/pulumi";
import * as vault from "@pulumi/vault";
const test = new vault.consul.SecretBackend("test", {
path: "consul",
description: "Manages the Consul backend",
address: "127.0.0.1:8500",
token: "4240861b-ce3d-8530-115a-521ff070dd29",
});
import pulumi
import pulumi_vault as vault
test = vault.consul.SecretBackend("test",
path="consul",
description="Manages the Consul backend",
address="127.0.0.1:8500",
token="4240861b-ce3d-8530-115a-521ff070dd29")
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vault = Pulumi.Vault;
return await Deployment.RunAsync(() =>
{
var test = new Vault.Consul.SecretBackend("test", new()
{
Path = "consul",
Description = "Manages the Consul backend",
Address = "127.0.0.1:8500",
Token = "4240861b-ce3d-8530-115a-521ff070dd29",
});
});
package main
import (
"github.com/pulumi/pulumi-vault/sdk/v6/go/vault/consul"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := consul.NewSecretBackend(ctx, "test", &consul.SecretBackendArgs{
Path: pulumi.String("consul"),
Description: pulumi.String("Manages the Consul backend"),
Address: pulumi.String("127.0.0.1:8500"),
Token: pulumi.String("4240861b-ce3d-8530-115a-521ff070dd29"),
})
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.vault.consul.SecretBackend;
import com.pulumi.vault.consul.SecretBackendArgs;
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 test = new SecretBackend("test", SecretBackendArgs.builder()
.path("consul")
.description("Manages the Consul backend")
.address("127.0.0.1:8500")
.token("4240861b-ce3d-8530-115a-521ff070dd29")
.build());
}
}
resources:
test:
type: vault:consul:SecretBackend
properties:
path: consul
description: Manages the Consul backend
address: 127.0.0.1:8500
token: 4240861b-ce3d-8530-115a-521ff070dd29

Creating a backend resource to bootstrap a new Consul instance:

import * as pulumi from "@pulumi/pulumi";
import * as vault from "@pulumi/vault";
const test = new vault.consul.SecretBackend("test", {
path: "consul",
description: "Bootstrap the Consul backend",
address: "127.0.0.1:8500",
bootstrap: true,
});
import pulumi
import pulumi_vault as vault
test = vault.consul.SecretBackend("test",
path="consul",
description="Bootstrap the Consul backend",
address="127.0.0.1:8500",
bootstrap=True)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vault = Pulumi.Vault;
return await Deployment.RunAsync(() =>
{
var test = new Vault.Consul.SecretBackend("test", new()
{
Path = "consul",
Description = "Bootstrap the Consul backend",
Address = "127.0.0.1:8500",
Bootstrap = true,
});
});
package main
import (
"github.com/pulumi/pulumi-vault/sdk/v6/go/vault/consul"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := consul.NewSecretBackend(ctx, "test", &consul.SecretBackendArgs{
Path: pulumi.String("consul"),
Description: pulumi.String("Bootstrap the Consul backend"),
Address: pulumi.String("127.0.0.1:8500"),
Bootstrap: pulumi.Bool(true),
})
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.vault.consul.SecretBackend;
import com.pulumi.vault.consul.SecretBackendArgs;
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 test = new SecretBackend("test", SecretBackendArgs.builder()
.path("consul")
.description("Bootstrap the Consul backend")
.address("127.0.0.1:8500")
.bootstrap(true)
.build());
}
}
resources:
test:
type: vault:consul:SecretBackend
properties:
path: consul
description: Bootstrap the Consul backend
address: 127.0.0.1:8500
bootstrap: true

Import

Consul secret backends can be imported using the path, e.g.

$ pulumi import vault:consul/secretBackend:SecretBackend example consul

Properties

Link copied to clipboard
val address: Output<String>

Specifies the address of the Consul instance, provided as "host:port" like "127.0.0.1:8500".

Link copied to clipboard
val bootstrap: Output<Boolean>?

Denotes a backend resource that is used to bootstrap the Consul ACL system. Only one resource may be used to bootstrap.

Link copied to clipboard
val caCert: Output<String>?

CA certificate to use when verifying Consul server certificate, must be x509 PEM encoded.

Link copied to clipboard
val clientCert: Output<String>?

Client certificate used for Consul's TLS communication, must be x509 PEM encoded and if this is set you need to also set client_key.

Link copied to clipboard
val clientKey: Output<String>?

Client key used for Consul's TLS communication, must be x509 PEM encoded and if this is set you need to also set client_cert.

Link copied to clipboard

The default TTL for credentials issued by this backend.

Link copied to clipboard
val description: Output<String>?

A human-friendly description for this backend.

Link copied to clipboard
val disableRemount: Output<Boolean>?

If set, opts out of mount migration on path updates. See here for more info on Mount Migration

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val local: Output<Boolean>?

Specifies if the secret backend is local only.

Link copied to clipboard
val maxLeaseTtlSeconds: Output<Int>?

The maximum TTL that can be requested for credentials issued by this backend.

Link copied to clipboard
val namespace: Output<String>?

The namespace to provision the resource in. The value should not contain leading or trailing forward slashes. The namespace is always relative to the provider's configured namespace. Available only for Vault Enterprise.

Link copied to clipboard
val path: Output<String>?

The unique location this backend should be mounted at. Must not begin or end with a /. Defaults to consul.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val scheme: Output<String>?

Specifies the URL scheme to use. Defaults to http.

Link copied to clipboard
val token: Output<String>?

Specifies the Consul token to use when managing or issuing new tokens.

Link copied to clipboard
val urn: Output<String>