gcp.secretmanager.Secret
Explore with Pulumi AI
A Secret is a logical secret whose value and versions can be accessed.
To get more information about Secret, see:
Example Usage
Secret Config Basic
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var secret_basic = new Gcp.SecretManager.Secret("secret-basic", new()
{
Labels =
{
{ "label", "my-label" },
},
Replication = new Gcp.SecretManager.Inputs.SecretReplicationArgs
{
UserManaged = new Gcp.SecretManager.Inputs.SecretReplicationUserManagedArgs
{
Replicas = new[]
{
new Gcp.SecretManager.Inputs.SecretReplicationUserManagedReplicaArgs
{
Location = "us-central1",
},
new Gcp.SecretManager.Inputs.SecretReplicationUserManagedReplicaArgs
{
Location = "us-east1",
},
},
},
},
SecretId = "secret",
});
});
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/secretmanager"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := secretmanager.NewSecret(ctx, "secret-basic", &secretmanager.SecretArgs{
Labels: pulumi.StringMap{
"label": pulumi.String("my-label"),
},
Replication: &secretmanager.SecretReplicationArgs{
UserManaged: &secretmanager.SecretReplicationUserManagedArgs{
Replicas: secretmanager.SecretReplicationUserManagedReplicaArray{
&secretmanager.SecretReplicationUserManagedReplicaArgs{
Location: pulumi.String("us-central1"),
},
&secretmanager.SecretReplicationUserManagedReplicaArgs{
Location: pulumi.String("us-east1"),
},
},
},
},
SecretId: pulumi.String("secret"),
})
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.gcp.secretmanager.Secret;
import com.pulumi.gcp.secretmanager.SecretArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationUserManagedArgs;
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 secret_basic = new Secret("secret-basic", SecretArgs.builder()
.labels(Map.of("label", "my-label"))
.replication(SecretReplicationArgs.builder()
.userManaged(SecretReplicationUserManagedArgs.builder()
.replicas(
SecretReplicationUserManagedReplicaArgs.builder()
.location("us-central1")
.build(),
SecretReplicationUserManagedReplicaArgs.builder()
.location("us-east1")
.build())
.build())
.build())
.secretId("secret")
.build());
}
}
import pulumi
import pulumi_gcp as gcp
secret_basic = gcp.secretmanager.Secret("secret-basic",
labels={
"label": "my-label",
},
replication=gcp.secretmanager.SecretReplicationArgs(
user_managed=gcp.secretmanager.SecretReplicationUserManagedArgs(
replicas=[
gcp.secretmanager.SecretReplicationUserManagedReplicaArgs(
location="us-central1",
),
gcp.secretmanager.SecretReplicationUserManagedReplicaArgs(
location="us-east1",
),
],
),
),
secret_id="secret")
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const secret_basic = new gcp.secretmanager.Secret("secret-basic", {
labels: {
label: "my-label",
},
replication: {
userManaged: {
replicas: [
{
location: "us-central1",
},
{
location: "us-east1",
},
],
},
},
secretId: "secret",
});
resources:
secret-basic:
type: gcp:secretmanager:Secret
properties:
labels:
label: my-label
replication:
userManaged:
replicas:
- location: us-central1
- location: us-east1
secretId: secret
Secret With Annotations
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var secret_with_annotations = new Gcp.SecretManager.Secret("secret-with-annotations", new()
{
Annotations =
{
{ "key1", "someval" },
{ "key2", "someval2" },
{ "key3", "someval3" },
{ "key4", "someval4" },
{ "key5", "someval5" },
},
Labels =
{
{ "label", "my-label" },
},
Replication = new Gcp.SecretManager.Inputs.SecretReplicationArgs
{
Auto = null,
},
SecretId = "secret",
});
});
package main
import (
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/secretmanager"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := secretmanager.NewSecret(ctx, "secret-with-annotations", &secretmanager.SecretArgs{
Annotations: pulumi.StringMap{
"key1": pulumi.String("someval"),
"key2": pulumi.String("someval2"),
"key3": pulumi.String("someval3"),
"key4": pulumi.String("someval4"),
"key5": pulumi.String("someval5"),
},
Labels: pulumi.StringMap{
"label": pulumi.String("my-label"),
},
Replication: &secretmanager.SecretReplicationArgs{
Auto: nil,
},
SecretId: pulumi.String("secret"),
})
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.gcp.secretmanager.Secret;
import com.pulumi.gcp.secretmanager.SecretArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationAutoArgs;
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 secret_with_annotations = new Secret("secret-with-annotations", SecretArgs.builder()
.annotations(Map.ofEntries(
Map.entry("key1", "someval"),
Map.entry("key2", "someval2"),
Map.entry("key3", "someval3"),
Map.entry("key4", "someval4"),
Map.entry("key5", "someval5")
))
.labels(Map.of("label", "my-label"))
.replication(SecretReplicationArgs.builder()
.auto()
.build())
.secretId("secret")
.build());
}
}
import pulumi
import pulumi_gcp as gcp
secret_with_annotations = gcp.secretmanager.Secret("secret-with-annotations",
annotations={
"key1": "someval",
"key2": "someval2",
"key3": "someval3",
"key4": "someval4",
"key5": "someval5",
},
labels={
"label": "my-label",
},
replication=gcp.secretmanager.SecretReplicationArgs(
auto=gcp.secretmanager.SecretReplicationAutoArgs(),
),
secret_id="secret")
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const secret_with_annotations = new gcp.secretmanager.Secret("secret-with-annotations", {
annotations: {
key1: "someval",
key2: "someval2",
key3: "someval3",
key4: "someval4",
key5: "someval5",
},
labels: {
label: "my-label",
},
replication: {
auto: {},
},
secretId: "secret",
});
resources:
secret-with-annotations:
type: gcp:secretmanager:Secret
properties:
annotations:
key1: someval
key2: someval2
key3: someval3
key4: someval4
key5: someval5
labels:
label: my-label
replication:
auto: {}
secretId: secret
Secret With Automatic Cmek
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var project = Gcp.Organizations.GetProject.Invoke();
var kms_secret_binding = new Gcp.Kms.CryptoKeyIAMMember("kms-secret-binding", new()
{
CryptoKeyId = "kms-key",
Role = "roles/cloudkms.cryptoKeyEncrypterDecrypter",
Member = $"serviceAccount:service-{project.Apply(getProjectResult => getProjectResult.Number)}@gcp-sa-secretmanager.iam.gserviceaccount.com",
});
var secret_with_automatic_cmek = new Gcp.SecretManager.Secret("secret-with-automatic-cmek", new()
{
SecretId = "secret",
Replication = new Gcp.SecretManager.Inputs.SecretReplicationArgs
{
Auto = new Gcp.SecretManager.Inputs.SecretReplicationAutoArgs
{
CustomerManagedEncryption = new Gcp.SecretManager.Inputs.SecretReplicationAutoCustomerManagedEncryptionArgs
{
KmsKeyName = "kms-key",
},
},
},
}, new CustomResourceOptions
{
DependsOn = new[]
{
kms_secret_binding,
},
});
});
package main
import (
"fmt"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/kms"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/organizations"
"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/secretmanager"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
project, err := organizations.LookupProject(ctx, nil, nil)
if err != nil {
return err
}
_, err = kms.NewCryptoKeyIAMMember(ctx, "kms-secret-binding", &kms.CryptoKeyIAMMemberArgs{
CryptoKeyId: pulumi.String("kms-key"),
Role: pulumi.String("roles/cloudkms.cryptoKeyEncrypterDecrypter"),
Member: pulumi.String(fmt.Sprintf("serviceAccount:service-%v@gcp-sa-secretmanager.iam.gserviceaccount.com", project.Number)),
})
if err != nil {
return err
}
_, err = secretmanager.NewSecret(ctx, "secret-with-automatic-cmek", &secretmanager.SecretArgs{
SecretId: pulumi.String("secret"),
Replication: &secretmanager.SecretReplicationArgs{
Auto: &secretmanager.SecretReplicationAutoArgs{
CustomerManagedEncryption: &secretmanager.SecretReplicationAutoCustomerManagedEncryptionArgs{
KmsKeyName: pulumi.String("kms-key"),
},
},
},
}, pulumi.DependsOn([]pulumi.Resource{
kms_secret_binding,
}))
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.gcp.organizations.OrganizationsFunctions;
import com.pulumi.gcp.organizations.inputs.GetProjectArgs;
import com.pulumi.gcp.kms.CryptoKeyIAMMember;
import com.pulumi.gcp.kms.CryptoKeyIAMMemberArgs;
import com.pulumi.gcp.secretmanager.Secret;
import com.pulumi.gcp.secretmanager.SecretArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationAutoArgs;
import com.pulumi.gcp.secretmanager.inputs.SecretReplicationAutoCustomerManagedEncryptionArgs;
import com.pulumi.resources.CustomResourceOptions;
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 project = OrganizationsFunctions.getProject();
var kms_secret_binding = new CryptoKeyIAMMember("kms-secret-binding", CryptoKeyIAMMemberArgs.builder()
.cryptoKeyId("kms-key")
.role("roles/cloudkms.cryptoKeyEncrypterDecrypter")
.member(String.format("serviceAccount:service-%s@gcp-sa-secretmanager.iam.gserviceaccount.com", project.applyValue(getProjectResult -> getProjectResult.number())))
.build());
var secret_with_automatic_cmek = new Secret("secret-with-automatic-cmek", SecretArgs.builder()
.secretId("secret")
.replication(SecretReplicationArgs.builder()
.auto(SecretReplicationAutoArgs.builder()
.customerManagedEncryption(SecretReplicationAutoCustomerManagedEncryptionArgs.builder()
.kmsKeyName("kms-key")
.build())
.build())
.build())
.build(), CustomResourceOptions.builder()
.dependsOn(kms_secret_binding)
.build());
}
}
import pulumi
import pulumi_gcp as gcp
project = gcp.organizations.get_project()
kms_secret_binding = gcp.kms.CryptoKeyIAMMember("kms-secret-binding",
crypto_key_id="kms-key",
role="roles/cloudkms.cryptoKeyEncrypterDecrypter",
member=f"serviceAccount:service-{project.number}@gcp-sa-secretmanager.iam.gserviceaccount.com")
secret_with_automatic_cmek = gcp.secretmanager.Secret("secret-with-automatic-cmek",
secret_id="secret",
replication=gcp.secretmanager.SecretReplicationArgs(
auto=gcp.secretmanager.SecretReplicationAutoArgs(
customer_managed_encryption=gcp.secretmanager.SecretReplicationAutoCustomerManagedEncryptionArgs(
kms_key_name="kms-key",
),
),
),
opts=pulumi.ResourceOptions(depends_on=[kms_secret_binding]))
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const project = gcp.organizations.getProject({});
const kms_secret_binding = new gcp.kms.CryptoKeyIAMMember("kms-secret-binding", {
cryptoKeyId: "kms-key",
role: "roles/cloudkms.cryptoKeyEncrypterDecrypter",
member: project.then(project => `serviceAccount:service-${project.number}@gcp-sa-secretmanager.iam.gserviceaccount.com`),
});
const secret_with_automatic_cmek = new gcp.secretmanager.Secret("secret-with-automatic-cmek", {
secretId: "secret",
replication: {
auto: {
customerManagedEncryption: {
kmsKeyName: "kms-key",
},
},
},
}, {
dependsOn: [kms_secret_binding],
});
resources:
kms-secret-binding:
type: gcp:kms:CryptoKeyIAMMember
properties:
cryptoKeyId: kms-key
role: roles/cloudkms.cryptoKeyEncrypterDecrypter
member: serviceAccount:service-${project.number}@gcp-sa-secretmanager.iam.gserviceaccount.com
secret-with-automatic-cmek:
type: gcp:secretmanager:Secret
properties:
secretId: secret
replication:
auto:
customerManagedEncryption:
kmsKeyName: kms-key
options:
dependson:
- ${["kms-secret-binding"]}
variables:
project:
fn::invoke:
Function: gcp:organizations:getProject
Arguments: {}
Create Secret Resource
new Secret(name: string, args: SecretArgs, opts?: CustomResourceOptions);
@overload
def Secret(resource_name: str,
opts: Optional[ResourceOptions] = None,
annotations: Optional[Mapping[str, str]] = None,
expire_time: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
project: Optional[str] = None,
replication: Optional[SecretReplicationArgs] = None,
rotation: Optional[SecretRotationArgs] = None,
secret_id: Optional[str] = None,
topics: Optional[Sequence[SecretTopicArgs]] = None,
ttl: Optional[str] = None,
version_aliases: Optional[Mapping[str, str]] = None)
@overload
def Secret(resource_name: str,
args: SecretArgs,
opts: Optional[ResourceOptions] = None)
func NewSecret(ctx *Context, name string, args SecretArgs, opts ...ResourceOption) (*Secret, error)
public Secret(string name, SecretArgs args, CustomResourceOptions? opts = null)
public Secret(String name, SecretArgs args)
public Secret(String name, SecretArgs args, CustomResourceOptions options)
type: gcp:secretmanager:Secret
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SecretArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args SecretArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args SecretArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args SecretArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args SecretArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Secret Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
The Secret resource accepts the following input properties:
- Replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- Secret
Id string This must be unique within the project.
- Annotations Dictionary<string, string>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- Expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- Labels Dictionary<string, string>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- Topics
List<Secret
Topic> A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- Ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- Version
Aliases Dictionary<string, string> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- Replication
Secret
Replication Args The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- Secret
Id string This must be unique within the project.
- Annotations map[string]string
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- Expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- Labels map[string]string
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Rotation
Secret
Rotation Args The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- Topics
[]Secret
Topic Args A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- Ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- Version
Aliases map[string]string Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- secret
Id String This must be unique within the project.
- annotations Map<String,String>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- expire
Time String Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Map<String,String>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- topics
List<Secret
Topic> A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl String
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases Map<String,String> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- secret
Id string This must be unique within the project.
- annotations {[key: string]: string}
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels {[key: string]: string}
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- topics
Secret
Topic[] A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases {[key: string]: string} Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- replication
Secret
Replication Args The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- secret_
id str This must be unique within the project.
- annotations Mapping[str, str]
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- expire_
time str Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Mapping[str, str]
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- rotation
Secret
Rotation Args The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- topics
Sequence[Secret
Topic Args] A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl str
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version_
aliases Mapping[str, str] Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- replication Property Map
The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- secret
Id String This must be unique within the project.
- annotations Map<String>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- expire
Time String Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Map<String>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- rotation Property Map
The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- topics List<Property Map>
A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl String
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases Map<String> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Outputs
All input properties are implicitly available as output properties. Additionally, the Secret resource produces the following output properties:
- Create
Time string The time at which the Secret was created.
- Effective
Annotations Dictionary<string, string> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- Effective
Labels Dictionary<string, string> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- Pulumi
Labels Dictionary<string, string> The combination of labels configured directly on the resource and default labels configured on the provider.
- Create
Time string The time at which the Secret was created.
- Effective
Annotations map[string]string All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- Effective
Labels map[string]string All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Id string
The provider-assigned unique ID for this managed resource.
- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- Pulumi
Labels map[string]string The combination of labels configured directly on the resource and default labels configured on the provider.
- create
Time String The time at which the Secret was created.
- effective
Annotations Map<String,String> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels Map<String,String> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- id String
The provider-assigned unique ID for this managed resource.
- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- pulumi
Labels Map<String,String> The combination of labels configured directly on the resource and default labels configured on the provider.
- create
Time string The time at which the Secret was created.
- effective
Annotations {[key: string]: string} All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels {[key: string]: string} All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- id string
The provider-assigned unique ID for this managed resource.
- name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- pulumi
Labels {[key: string]: string} The combination of labels configured directly on the resource and default labels configured on the provider.
- create_
time str The time at which the Secret was created.
- effective_
annotations Mapping[str, str] All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective_
labels Mapping[str, str] All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- id str
The provider-assigned unique ID for this managed resource.
- name str
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- pulumi_
labels Mapping[str, str] The combination of labels configured directly on the resource and default labels configured on the provider.
- create
Time String The time at which the Secret was created.
- effective
Annotations Map<String> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels Map<String> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- id String
The provider-assigned unique ID for this managed resource.
- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- pulumi
Labels Map<String> The combination of labels configured directly on the resource and default labels configured on the provider.
Look up Existing Secret Resource
Get an existing Secret resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: SecretState, opts?: CustomResourceOptions): Secret
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
annotations: Optional[Mapping[str, str]] = None,
create_time: Optional[str] = None,
effective_annotations: Optional[Mapping[str, str]] = None,
effective_labels: Optional[Mapping[str, str]] = None,
expire_time: Optional[str] = None,
labels: Optional[Mapping[str, str]] = None,
name: Optional[str] = None,
project: Optional[str] = None,
pulumi_labels: Optional[Mapping[str, str]] = None,
replication: Optional[SecretReplicationArgs] = None,
rotation: Optional[SecretRotationArgs] = None,
secret_id: Optional[str] = None,
topics: Optional[Sequence[SecretTopicArgs]] = None,
ttl: Optional[str] = None,
version_aliases: Optional[Mapping[str, str]] = None) -> Secret
func GetSecret(ctx *Context, name string, id IDInput, state *SecretState, opts ...ResourceOption) (*Secret, error)
public static Secret Get(string name, Input<string> id, SecretState? state, CustomResourceOptions? opts = null)
public static Secret get(String name, Output<String> id, SecretState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Annotations Dictionary<string, string>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- Create
Time string The time at which the Secret was created.
- Effective
Annotations Dictionary<string, string> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- Effective
Labels Dictionary<string, string> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- Labels Dictionary<string, string>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Pulumi
Labels Dictionary<string, string> The combination of labels configured directly on the resource and default labels configured on the provider.
- Replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- Rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- Secret
Id string This must be unique within the project.
- Topics
List<Secret
Topic> A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- Ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- Version
Aliases Dictionary<string, string> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- Annotations map[string]string
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- Create
Time string The time at which the Secret was created.
- Effective
Annotations map[string]string All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- Effective
Labels map[string]string All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- Expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- Labels map[string]string
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- Project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- Pulumi
Labels map[string]string The combination of labels configured directly on the resource and default labels configured on the provider.
- Replication
Secret
Replication Args The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- Rotation
Secret
Rotation Args The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- Secret
Id string This must be unique within the project.
- Topics
[]Secret
Topic Args A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- Ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- Version
Aliases map[string]string Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- annotations Map<String,String>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- create
Time String The time at which the Secret was created.
- effective
Annotations Map<String,String> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels Map<String,String> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- expire
Time String Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Map<String,String>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- pulumi
Labels Map<String,String> The combination of labels configured directly on the resource and default labels configured on the provider.
- replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- secret
Id String This must be unique within the project.
- topics
List<Secret
Topic> A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl String
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases Map<String,String> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- annotations {[key: string]: string}
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- create
Time string The time at which the Secret was created.
- effective
Annotations {[key: string]: string} All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels {[key: string]: string} All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- expire
Time string Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels {[key: string]: string}
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- project string
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- pulumi
Labels {[key: string]: string} The combination of labels configured directly on the resource and default labels configured on the provider.
- replication
Secret
Replication The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- rotation
Secret
Rotation The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- secret
Id string This must be unique within the project.
- topics
Secret
Topic[] A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl string
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases {[key: string]: string} Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- annotations Mapping[str, str]
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- create_
time str The time at which the Secret was created.
- effective_
annotations Mapping[str, str] All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective_
labels Mapping[str, str] All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- expire_
time str Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Mapping[str, str]
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name str
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- project str
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- pulumi_
labels Mapping[str, str] The combination of labels configured directly on the resource and default labels configured on the provider.
- replication
Secret
Replication Args The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- rotation
Secret
Rotation Args The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- secret_
id str This must be unique within the project.
- topics
Sequence[Secret
Topic Args] A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl str
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version_
aliases Mapping[str, str] Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
- annotations Map<String>
Custom metadata about the secret. Annotations are distinct from various forms of labels. Annotations exist to allow client tools to store their own state information without requiring a database. Annotation keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, begin and end with an alphanumeric character ([a-z0-9A-Z]), and may have dashes (-), underscores (_), dots (.), and alphanumerics in between these symbols. The total size of annotation keys and values must be less than 16KiB. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the annotations present in your configuration. Please refer to the field
effective_annotations
for all of the annotations present on the resource.- create
Time String The time at which the Secret was created.
- effective
Annotations Map<String> All of annotations (key/value pairs) present on the resource in GCP, including the annotations configured through Terraform, other clients and services.
- effective
Labels Map<String> All of labels (key/value pairs) present on the resource in GCP, including the labels configured through Pulumi, other clients and services.
- expire
Time String Timestamp in UTC when the Secret is scheduled to expire. This is always provided on output, regardless of what was sent on input. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z". Only one of
expire_time
orttl
can be provided.- labels Map<String>
The labels assigned to this Secret. Label keys must be between 1 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}][\p{Ll}\p{Lo}\p{N}-]{0,62} Label values must be between 0 and 63 characters long, have a UTF-8 encoding of maximum 128 bytes, and must conform to the following PCRE regular expression: [\p{Ll}\p{Lo}\p{N}-]{0,63} No more than 64 labels can be assigned to a given resource. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Note: This field is non-authoritative, and will only manage the labels present in your configuration. Please refer to the field
effective_labels
for all of the labels present on the resource.- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- project String
The ID of the project in which the resource belongs. If it is not provided, the provider project is used.
- pulumi
Labels Map<String> The combination of labels configured directly on the resource and default labels configured on the provider.
- replication Property Map
The replication policy of the secret data attached to the Secret. It cannot be changed after the Secret has been created. Structure is documented below.
- rotation Property Map
The rotation time and period for a Secret. At
next_rotation_time
, Secret Manager will send a Pub/Sub notification to the topics configured on the Secret.topics
must be set to configure rotation. Structure is documented below.- secret
Id String This must be unique within the project.
- topics List<Property Map>
A list of up to 10 Pub/Sub topics to which messages are published when control plane operations are called on the secret or its versions. Structure is documented below.
- ttl String
The TTL for the Secret. A duration in seconds with up to nine fractional digits, terminated by 's'. Example: "3.5s". Only one of
ttl
orexpire_time
can be provided.- version
Aliases Map<String> Mapping from version alias to version name. A version alias is a string with a maximum length of 63 characters and can contain uppercase and lowercase letters, numerals, and the hyphen (-) and underscore ('_') characters. An alias string must start with a letter and cannot be the string 'latest' or 'NEW'. No more than 50 aliases can be assigned to a given secret. An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Supporting Types
SecretReplication, SecretReplicationArgs
- Auto
Secret
Replication Auto The Secret will automatically be replicated without any restrictions. Structure is documented below.
- User
Managed SecretReplication User Managed The Secret will be replicated to the regions specified by the user. Structure is documented below.
- Auto
Secret
Replication Auto The Secret will automatically be replicated without any restrictions. Structure is documented below.
- User
Managed SecretReplication User Managed The Secret will be replicated to the regions specified by the user. Structure is documented below.
- auto
Secret
Replication Auto The Secret will automatically be replicated without any restrictions. Structure is documented below.
- user
Managed SecretReplication User Managed The Secret will be replicated to the regions specified by the user. Structure is documented below.
- auto
Secret
Replication Auto The Secret will automatically be replicated without any restrictions. Structure is documented below.
- user
Managed SecretReplication User Managed The Secret will be replicated to the regions specified by the user. Structure is documented below.
- auto
Secret
Replication Auto The Secret will automatically be replicated without any restrictions. Structure is documented below.
- user_
managed SecretReplication User Managed The Secret will be replicated to the regions specified by the user. Structure is documented below.
- auto Property Map
The Secret will automatically be replicated without any restrictions. Structure is documented below.
- user
Managed Property Map The Secret will be replicated to the regions specified by the user. Structure is documented below.
SecretReplicationAuto, SecretReplicationAutoArgs
- Customer
Managed SecretEncryption Replication Auto Customer Managed Encryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
- Customer
Managed SecretEncryption Replication Auto Customer Managed Encryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
- customer
Managed SecretEncryption Replication Auto Customer Managed Encryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
- customer
Managed SecretEncryption Replication Auto Customer Managed Encryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
- customer_
managed_ Secretencryption Replication Auto Customer Managed Encryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
- customer
Managed Property MapEncryption The customer-managed encryption configuration of the Secret. If no configuration is provided, Google-managed default encryption is used. Structure is documented below.
SecretReplicationAutoCustomerManagedEncryption, SecretReplicationAutoCustomerManagedEncryptionArgs
- Kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- Kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key StringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms_
key_ strname Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key StringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
SecretReplicationUserManaged, SecretReplicationUserManagedArgs
- Replicas
List<Secret
Replication User Managed Replica> The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
- Replicas
[]Secret
Replication User Managed Replica The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
- replicas
List<Secret
Replication User Managed Replica> The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
- replicas
Secret
Replication User Managed Replica[] The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
- replicas
Sequence[Secret
Replication User Managed Replica] The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
- replicas List<Property Map>
The list of Replicas for this Secret. Cannot be empty. Structure is documented below.
SecretReplicationUserManagedReplica, SecretReplicationUserManagedReplicaArgs
- Location string
The canonical IDs of the location to replicate data. For example: "us-east1".
- Customer
Managed SecretEncryption Replication User Managed Replica Customer Managed Encryption Customer Managed Encryption for the secret. Structure is documented below.
- Location string
The canonical IDs of the location to replicate data. For example: "us-east1".
- Customer
Managed SecretEncryption Replication User Managed Replica Customer Managed Encryption Customer Managed Encryption for the secret. Structure is documented below.
- location String
The canonical IDs of the location to replicate data. For example: "us-east1".
- customer
Managed SecretEncryption Replication User Managed Replica Customer Managed Encryption Customer Managed Encryption for the secret. Structure is documented below.
- location string
The canonical IDs of the location to replicate data. For example: "us-east1".
- customer
Managed SecretEncryption Replication User Managed Replica Customer Managed Encryption Customer Managed Encryption for the secret. Structure is documented below.
- location str
The canonical IDs of the location to replicate data. For example: "us-east1".
- customer_
managed_ Secretencryption Replication User Managed Replica Customer Managed Encryption Customer Managed Encryption for the secret. Structure is documented below.
- location String
The canonical IDs of the location to replicate data. For example: "us-east1".
- customer
Managed Property MapEncryption Customer Managed Encryption for the secret. Structure is documented below.
SecretReplicationUserManagedReplicaCustomerManagedEncryption, SecretReplicationUserManagedReplicaCustomerManagedEncryptionArgs
- Kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- Kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key StringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key stringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms_
key_ strname Describes the Cloud KMS encryption key that will be used to protect destination secret.
- kms
Key StringName Describes the Cloud KMS encryption key that will be used to protect destination secret.
SecretRotation, SecretRotationArgs
- Next
Rotation stringTime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- Rotation
Period string The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
- Next
Rotation stringTime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- Rotation
Period string The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
- next
Rotation StringTime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- rotation
Period String The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
- next
Rotation stringTime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- rotation
Period string The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
- next_
rotation_ strtime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- rotation_
period str The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
- next
Rotation StringTime Timestamp in UTC at which the Secret is scheduled to rotate. A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".
- rotation
Period String The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years). If rotationPeriod is set,
next_rotation_time
must be set.next_rotation_time
will be advanced by this period when the service automatically sends rotation notifications.
SecretTopic, SecretTopicArgs
- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- Name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- name string
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- name str
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
- name String
The resource name of the Pub/Sub topic that will be published to, in the following format: projects//topics/. For publication to succeed, the Secret Manager Service Agent service account must have pubsub.publisher permissions on the topic.
Import
Secret can be imported using any of these accepted formats* projects/{{project}}/secrets/{{secret_id}}
* {{project}}/{{secret_id}}
* {{secret_id}}
In Terraform v1.5.0 and later, use an import
block to import Secret using one of the formats above. For exampletf import {
id = “projects/{{project}}/secrets/{{secret_id}}”
to = google_secret_manager_secret.default }
$ pulumi import gcp:secretmanager/secret:Secret When using the [`terraform import` command](https://developer.hashicorp.com/terraform/cli/commands/import), Secret can be imported using one of the formats above. For example
$ pulumi import gcp:secretmanager/secret:Secret default projects/{{project}}/secrets/{{secret_id}}
$ pulumi import gcp:secretmanager/secret:Secret default {{project}}/{{secret_id}}
$ pulumi import gcp:secretmanager/secret:Secret default {{secret_id}}
Package Details
- Repository
- Google Cloud (GCP) Classic pulumi/pulumi-gcp
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
google-beta
Terraform Provider.