Azure Native

Pulumi Official
Package maintained by Pulumi
v1.64.0 published on Wednesday, May 4, 2022 by Pulumi

KeyValue

The key-value resource along with all resource properties. API Version: 2020-07-01-preview.

Example Usage

KeyValues_CreateOrUpdate

using Pulumi;
using AzureNative = Pulumi.AzureNative;

class MyStack : Stack
{
    public MyStack()
    {
        var keyValue = new AzureNative.AppConfiguration.KeyValue("keyValue", new AzureNative.AppConfiguration.KeyValueArgs
        {
            ConfigStoreName = "contoso",
            KeyValueName = "myKey$myLabel",
            ResourceGroupName = "myResourceGroup",
            Tags = 
            {
                { "tag1", "tagValue1" },
                { "tag2", "tagValue2" },
            },
            Value = "myValue",
        });
    }

}
package main

import (
	"fmt"

	appconfiguration "github.com/pulumi/pulumi-azure-native/sdk/go/azure/appconfiguration"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := appconfiguration.NewKeyValue(ctx, "keyValue", &appconfiguration.KeyValueArgs{
			ConfigStoreName:   pulumi.String("contoso"),
			KeyValueName:      pulumi.String(fmt.Sprintf("%v%v%v", "myKey", "$", "myLabel")),
			ResourceGroupName: pulumi.String("myResourceGroup"),
			Tags: pulumi.StringMap{
				"tag1": pulumi.String("tagValue1"),
				"tag2": pulumi.String("tagValue2"),
			},
			Value: pulumi.String("myValue"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import java.util.*;
import java.io.*;
import java.nio.*;
import com.pulumi.*;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var keyValue = new KeyValue("keyValue", KeyValueArgs.builder()        
            .configStoreName("contoso")
            .keyValueName("myKey$myLabel")
            .resourceGroupName("myResourceGroup")
            .tags(Map.ofEntries(
                Map.entry("tag1", "tagValue1"),
                Map.entry("tag2", "tagValue2")
            ))
            .value("myValue")
            .build());

        }
}
import pulumi
import pulumi_azure_native as azure_native

key_value = azure_native.appconfiguration.KeyValue("keyValue",
    config_store_name="contoso",
    key_value_name="myKey$myLabel",
    resource_group_name="myResourceGroup",
    tags={
        "tag1": "tagValue1",
        "tag2": "tagValue2",
    },
    value="myValue")
import * as pulumi from "@pulumi/pulumi";
import * as azure_native from "@pulumi/azure-native";

const keyValue = new azure_native.appconfiguration.KeyValue("keyValue", {
    configStoreName: "contoso",
    keyValueName: `myKey$myLabel`,
    resourceGroupName: "myResourceGroup",
    tags: {
        tag1: "tagValue1",
        tag2: "tagValue2",
    },
    value: "myValue",
});
resources:
  keyValue:
    type: azure-native:appconfiguration:KeyValue
    properties:
      configStoreName: contoso
      keyValueName: myKey$myLabel
      resourceGroupName: myResourceGroup
      tags:
        tag1: tagValue1
        tag2: tagValue2
      value: myValue

Create a KeyValue Resource

new KeyValue(name: string, args: KeyValueArgs, opts?: CustomResourceOptions);
@overload
def KeyValue(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             config_store_name: Optional[str] = None,
             content_type: Optional[str] = None,
             key_value_name: Optional[str] = None,
             resource_group_name: Optional[str] = None,
             tags: Optional[Mapping[str, str]] = None,
             value: Optional[str] = None)
@overload
def KeyValue(resource_name: str,
             args: KeyValueArgs,
             opts: Optional[ResourceOptions] = None)
func NewKeyValue(ctx *Context, name string, args KeyValueArgs, opts ...ResourceOption) (*KeyValue, error)
public KeyValue(string name, KeyValueArgs args, CustomResourceOptions? opts = null)
public KeyValue(String name, KeyValueArgs args)
public KeyValue(String name, KeyValueArgs args, CustomResourceOptions options)
type: azure-native:appconfiguration:KeyValue
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args KeyValueArgs
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 KeyValueArgs
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 KeyValueArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args KeyValueArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args KeyValueArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

KeyValue 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 KeyValue resource accepts the following input properties:

ConfigStoreName string

The name of the configuration store.

ResourceGroupName string

The name of the resource group to which the container registry belongs.

ContentType string

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

KeyValueName string

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

Tags Dictionary<string, string>

A dictionary of tags that can help identify what a key-value may be applicable for.

Value string

The value of the key-value.

ConfigStoreName string

The name of the configuration store.

ResourceGroupName string

The name of the resource group to which the container registry belongs.

ContentType string

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

KeyValueName string

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

Tags map[string]string

A dictionary of tags that can help identify what a key-value may be applicable for.

Value string

The value of the key-value.

configStoreName String

The name of the configuration store.

resourceGroupName String

The name of the resource group to which the container registry belongs.

contentType String

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

keyValueName String

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

tags Map

A dictionary of tags that can help identify what a key-value may be applicable for.

value String

The value of the key-value.

configStoreName string

The name of the configuration store.

resourceGroupName string

The name of the resource group to which the container registry belongs.

contentType string

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

keyValueName string

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

tags {[key: string]: string}

A dictionary of tags that can help identify what a key-value may be applicable for.

value string

The value of the key-value.

config_store_name str

The name of the configuration store.

resource_group_name str

The name of the resource group to which the container registry belongs.

content_type str

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

key_value_name str

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

tags Mapping[str, str]

A dictionary of tags that can help identify what a key-value may be applicable for.

value str

The value of the key-value.

configStoreName String

The name of the configuration store.

resourceGroupName String

The name of the resource group to which the container registry belongs.

contentType String

The content type of the key-value's value. Providing a proper content-type can enable transformations of values when they are retrieved by applications.

keyValueName String

Identifier of key and label combination. Key and label are joined by $ character. Label is optional.

tags Map

A dictionary of tags that can help identify what a key-value may be applicable for.

value String

The value of the key-value.

Outputs

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

ETag string

An ETag indicating the state of a key-value within a configuration store.

Id string

The provider-assigned unique ID for this managed resource.

Key string

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

Label string

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

LastModified string

The last time a modifying operation was performed on the given key-value.

Locked bool

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

Name string

The name of the resource.

Type string

The type of the resource.

ETag string

An ETag indicating the state of a key-value within a configuration store.

Id string

The provider-assigned unique ID for this managed resource.

Key string

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

Label string

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

LastModified string

The last time a modifying operation was performed on the given key-value.

Locked bool

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

Name string

The name of the resource.

Type string

The type of the resource.

eTag String

An ETag indicating the state of a key-value within a configuration store.

id String

The provider-assigned unique ID for this managed resource.

key String

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

label String

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

lastModified String

The last time a modifying operation was performed on the given key-value.

locked Boolean

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

name String

The name of the resource.

type String

The type of the resource.

eTag string

An ETag indicating the state of a key-value within a configuration store.

id string

The provider-assigned unique ID for this managed resource.

key string

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

label string

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

lastModified string

The last time a modifying operation was performed on the given key-value.

locked boolean

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

name string

The name of the resource.

type string

The type of the resource.

e_tag str

An ETag indicating the state of a key-value within a configuration store.

id str

The provider-assigned unique ID for this managed resource.

key str

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

label str

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

last_modified str

The last time a modifying operation was performed on the given key-value.

locked bool

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

name str

The name of the resource.

type str

The type of the resource.

eTag String

An ETag indicating the state of a key-value within a configuration store.

id String

The provider-assigned unique ID for this managed resource.

key String

The primary identifier of a key-value. The key is used in unison with the label to uniquely identify a key-value.

label String

A value used to group key-values. The label is used in unison with the key to uniquely identify a key-value.

lastModified String

The last time a modifying operation was performed on the given key-value.

locked Boolean

A value indicating whether the key-value is locked. A locked key-value may not be modified until it is unlocked.

name String

The name of the resource.

type String

The type of the resource.

Import

An existing resource can be imported using its type token, name, and identifier, e.g.

$ pulumi import azure-native:appconfiguration:KeyValue myKey$myLabel /subscriptions/c80fb759-c965-4c6a-9110-9b2b2d038882/resourceGroups/myResourceGroup/providers/Microsoft.AppConfiguration/configurationStores/contoso/keyValues/myKey$myLabel 

Package Details

Repository
https://github.com/pulumi/pulumi-azure-native
License
Apache-2.0