Sync Azure Destination
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as vault from "@pulumi/vault";
const az = new vault.secrets.SyncAzureDestination("az", {
name: "az-dest",
keyVaultUri: keyVaultUri,
clientId: clientId,
clientSecret: clientSecret,
tenantId: tenantId,
secretNameTemplate: "vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}",
customTags: {
foo: "bar",
},
});
Content copied to clipboard
import pulumi
import pulumi_vault as vault
az = vault.secrets.SyncAzureDestination("az",
name="az-dest",
key_vault_uri=key_vault_uri,
client_id=client_id,
client_secret=client_secret,
tenant_id=tenant_id,
secret_name_template="vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}",
custom_tags={
"foo": "bar",
})
Content copied to clipboard
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vault = Pulumi.Vault;
return await Deployment.RunAsync(() =>
{
var az = new Vault.Secrets.SyncAzureDestination("az", new()
{
Name = "az-dest",
KeyVaultUri = keyVaultUri,
ClientId = clientId,
ClientSecret = clientSecret,
TenantId = tenantId,
SecretNameTemplate = "vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}",
CustomTags =
{
{ "foo", "bar" },
},
});
});
Content copied to clipboard
package main
import (
"github.com/pulumi/pulumi-vault/sdk/v6/go/vault/secrets"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := secrets.NewSyncAzureDestination(ctx, "az", &secrets.SyncAzureDestinationArgs{
Name: pulumi.String("az-dest"),
KeyVaultUri: pulumi.Any(keyVaultUri),
ClientId: pulumi.Any(clientId),
ClientSecret: pulumi.Any(clientSecret),
TenantId: pulumi.Any(tenantId),
SecretNameTemplate: pulumi.String("vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}"),
CustomTags: pulumi.StringMap{
"foo": pulumi.String("bar"),
},
})
if err != nil {
return err
}
return nil
})
}
Content copied to clipboard
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vault.secrets.SyncAzureDestination;
import com.pulumi.vault.secrets.SyncAzureDestinationArgs;
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 az = new SyncAzureDestination("az", SyncAzureDestinationArgs.builder()
.name("az-dest")
.keyVaultUri(keyVaultUri)
.clientId(clientId)
.clientSecret(clientSecret)
.tenantId(tenantId)
.secretNameTemplate("vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}")
.customTags(Map.of("foo", "bar"))
.build());
}
}
Content copied to clipboard
resources:
az:
type: vault:secrets:SyncAzureDestination
properties:
name: az-dest
keyVaultUri: ${keyVaultUri}
clientId: ${clientId}
clientSecret: ${clientSecret}
tenantId: ${tenantId}
secretNameTemplate: vault_{{ .MountAccessor | lowercase }}_{{ .SecretPath | lowercase }}
customTags:
foo: bar
Content copied to clipboard
Import
Azure Secrets sync destinations can be imported using the name
, e.g.
$ pulumi import vault:secrets/syncAzureDestination:SyncAzureDestination az az-dest
Content copied to clipboard
Properties
Link copied to clipboard
Client Secret of an Azure app registration. Can be omitted and directly provided to Vault using the AZURE_CLIENT_SECRET
environment variable.
Link copied to clipboard
Custom tags to set on the secret managed at the destination.
Link copied to clipboard
Determines what level of information is synced as a distinct resource at the destination. Supports secret-path
and secret-key
.
Link copied to clipboard
URI of an existing Azure Key Vault instance. Can be omitted and directly provided to Vault using the KEY_VAULT_URI
environment variable.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Template describing how to generate external secret names. Supports a subset of the Go Template syntax.