Secret

Manages a Key Vault Secret.

Create a Secret Resource

new Secret(name: string, args: SecretArgs, opts?: CustomResourceOptions);
def Secret(resource_name, opts=None, content_type=None, expiration_date=None, key_vault_id=None, name=None, not_before_date=None, tags=None, value=None, __props__=None);
func NewSecret(ctx *Context, name string, args SecretArgs, opts ...ResourceOption) (*Secret, error)
public Secret(string name, SecretArgs args, CustomResourceOptions? opts = null)
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.
opts ResourceOptions
A bag of options that control this 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.

Secret Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The Secret resource accepts the following input properties:

KeyVaultId string

The ID of the Key Vault where the Secret should be created.

Value string

Specifies the value of the Key Vault Secret.

ContentType string

Specifies the content type for the Key Vault Secret.

ExpirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

Name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

NotBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

Tags Dictionary<string, string>

A mapping of tags to assign to the resource.

KeyVaultId string

The ID of the Key Vault where the Secret should be created.

Value string

Specifies the value of the Key Vault Secret.

ContentType string

Specifies the content type for the Key Vault Secret.

ExpirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

Name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

NotBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

Tags map[string]string

A mapping of tags to assign to the resource.

keyVaultId string

The ID of the Key Vault where the Secret should be created.

value string

Specifies the value of the Key Vault Secret.

contentType string

Specifies the content type for the Key Vault Secret.

expirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

notBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

tags {[key: string]: string}

A mapping of tags to assign to the resource.

key_vault_id str

The ID of the Key Vault where the Secret should be created.

value str

Specifies the value of the Key Vault Secret.

content_type str

Specifies the content type for the Key Vault Secret.

expiration_date str

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

name str

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

not_before_date str

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

tags Dict[str, str]

A mapping of tags to assign to the resource.

Outputs

All input properties are implicitly available as output properties. Additionally, the Secret resource produces the following output properties:

Id string
The provider-assigned unique ID for this managed resource.
Version string

The current version of the Key Vault Secret.

Id string
The provider-assigned unique ID for this managed resource.
Version string

The current version of the Key Vault Secret.

id string
The provider-assigned unique ID for this managed resource.
version string

The current version of the Key Vault Secret.

id str
The provider-assigned unique ID for this managed resource.
version str

The current version of the Key Vault Secret.

Look up an 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
static get(resource_name, id, opts=None, content_type=None, expiration_date=None, key_vault_id=None, name=None, not_before_date=None, tags=None, value=None, version=None, __props__=None);
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)
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.

The following state arguments are supported:

ContentType string

Specifies the content type for the Key Vault Secret.

ExpirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

KeyVaultId string

The ID of the Key Vault where the Secret should be created.

Name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

NotBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

Tags Dictionary<string, string>

A mapping of tags to assign to the resource.

Value string

Specifies the value of the Key Vault Secret.

Version string

The current version of the Key Vault Secret.

ContentType string

Specifies the content type for the Key Vault Secret.

ExpirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

KeyVaultId string

The ID of the Key Vault where the Secret should be created.

Name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

NotBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

Tags map[string]string

A mapping of tags to assign to the resource.

Value string

Specifies the value of the Key Vault Secret.

Version string

The current version of the Key Vault Secret.

contentType string

Specifies the content type for the Key Vault Secret.

expirationDate string

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

keyVaultId string

The ID of the Key Vault where the Secret should be created.

name string

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

notBeforeDate string

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

tags {[key: string]: string}

A mapping of tags to assign to the resource.

value string

Specifies the value of the Key Vault Secret.

version string

The current version of the Key Vault Secret.

content_type str

Specifies the content type for the Key Vault Secret.

expiration_date str

Expiration UTC datetime (Y-m-d’T’H:M:S’Z’).

key_vault_id str

The ID of the Key Vault where the Secret should be created.

name str

Specifies the name of the Key Vault Secret. Changing this forces a new resource to be created.

not_before_date str

Key not usable before the provided UTC datetime (Y-m-d’T’H:M:S’Z’).

tags Dict[str, str]

A mapping of tags to assign to the resource.

value str

Specifies the value of the Key Vault Secret.

version str

The current version of the Key Vault Secret.

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes
This Pulumi package is based on the azurerm Terraform Provider.