1. Packages
  2. Etcd Provider
  3. API Docs
  4. SynchronizedKeyPrefixes
etcd 0.10.0 published on Tuesday, Apr 15, 2025 by ferlab-ste-justine

etcd.SynchronizedKeyPrefixes

Explore with Pulumi AI

etcd logo
etcd 0.10.0 published on Tuesday, Apr 15, 2025 by ferlab-ste-justine

    Synchronizes a source key prefix with a destination key prefix either once when the resources is created or whenever the resource is applied. Note that the resource assumes that the destination is not being written to during synchronization.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as etcd from "@pulumi/etcd";
    
    const syncMyApp = new etcd.SynchronizedKeyPrefixes("syncMyApp", {
        destinationPrefix: "/my-app-state-with-the-prefix-i-want/",
        recurrence: "onchange",
        sourcePrefix: "/my-app-state-with-bad-prefix/",
    });
    
    import pulumi
    import pulumi_etcd as etcd
    
    sync_my_app = etcd.SynchronizedKeyPrefixes("syncMyApp",
        destination_prefix="/my-app-state-with-the-prefix-i-want/",
        recurrence="onchange",
        source_prefix="/my-app-state-with-bad-prefix/")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/etcd/etcd"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := etcd.NewSynchronizedKeyPrefixes(ctx, "syncMyApp", &etcd.SynchronizedKeyPrefixesArgs{
    			DestinationPrefix: pulumi.String("/my-app-state-with-the-prefix-i-want/"),
    			Recurrence:        pulumi.String("onchange"),
    			SourcePrefix:      pulumi.String("/my-app-state-with-bad-prefix/"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Etcd = Pulumi.Etcd;
    
    return await Deployment.RunAsync(() => 
    {
        var syncMyApp = new Etcd.SynchronizedKeyPrefixes("syncMyApp", new()
        {
            DestinationPrefix = "/my-app-state-with-the-prefix-i-want/",
            Recurrence = "onchange",
            SourcePrefix = "/my-app-state-with-bad-prefix/",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.etcd.SynchronizedKeyPrefixes;
    import com.pulumi.etcd.SynchronizedKeyPrefixesArgs;
    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 syncMyApp = new SynchronizedKeyPrefixes("syncMyApp", SynchronizedKeyPrefixesArgs.builder()
                .destinationPrefix("/my-app-state-with-the-prefix-i-want/")
                .recurrence("onchange")
                .sourcePrefix("/my-app-state-with-bad-prefix/")
                .build());
    
        }
    }
    
    resources:
      syncMyApp:
        type: etcd:SynchronizedKeyPrefixes
        properties:
          destinationPrefix: /my-app-state-with-the-prefix-i-want/
          recurrence: onchange
          sourcePrefix: /my-app-state-with-bad-prefix/
    

    Create SynchronizedKeyPrefixes Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new SynchronizedKeyPrefixes(name: string, args: SynchronizedKeyPrefixesArgs, opts?: CustomResourceOptions);
    @overload
    def SynchronizedKeyPrefixes(resource_name: str,
                                args: SynchronizedKeyPrefixesArgs,
                                opts: Optional[ResourceOptions] = None)
    
    @overload
    def SynchronizedKeyPrefixes(resource_name: str,
                                opts: Optional[ResourceOptions] = None,
                                destination_prefix: Optional[str] = None,
                                source_prefix: Optional[str] = None,
                                recurrence: Optional[str] = None,
                                synchronized_key_prefixes_id: Optional[str] = None)
    func NewSynchronizedKeyPrefixes(ctx *Context, name string, args SynchronizedKeyPrefixesArgs, opts ...ResourceOption) (*SynchronizedKeyPrefixes, error)
    public SynchronizedKeyPrefixes(string name, SynchronizedKeyPrefixesArgs args, CustomResourceOptions? opts = null)
    public SynchronizedKeyPrefixes(String name, SynchronizedKeyPrefixesArgs args)
    public SynchronizedKeyPrefixes(String name, SynchronizedKeyPrefixesArgs args, CustomResourceOptions options)
    
    type: etcd:SynchronizedKeyPrefixes
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

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

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var synchronizedKeyPrefixesResource = new Etcd.SynchronizedKeyPrefixes("synchronizedKeyPrefixesResource", new()
    {
        DestinationPrefix = "string",
        SourcePrefix = "string",
        Recurrence = "string",
        SynchronizedKeyPrefixesId = "string",
    });
    
    example, err := etcd.NewSynchronizedKeyPrefixes(ctx, "synchronizedKeyPrefixesResource", &etcd.SynchronizedKeyPrefixesArgs{
    	DestinationPrefix:         pulumi.String("string"),
    	SourcePrefix:              pulumi.String("string"),
    	Recurrence:                pulumi.String("string"),
    	SynchronizedKeyPrefixesId: pulumi.String("string"),
    })
    
    var synchronizedKeyPrefixesResource = new SynchronizedKeyPrefixes("synchronizedKeyPrefixesResource", SynchronizedKeyPrefixesArgs.builder()
        .destinationPrefix("string")
        .sourcePrefix("string")
        .recurrence("string")
        .synchronizedKeyPrefixesId("string")
        .build());
    
    synchronized_key_prefixes_resource = etcd.SynchronizedKeyPrefixes("synchronizedKeyPrefixesResource",
        destination_prefix="string",
        source_prefix="string",
        recurrence="string",
        synchronized_key_prefixes_id="string")
    
    const synchronizedKeyPrefixesResource = new etcd.SynchronizedKeyPrefixes("synchronizedKeyPrefixesResource", {
        destinationPrefix: "string",
        sourcePrefix: "string",
        recurrence: "string",
        synchronizedKeyPrefixesId: "string",
    });
    
    type: etcd:SynchronizedKeyPrefixes
    properties:
        destinationPrefix: string
        recurrence: string
        sourcePrefix: string
        synchronizedKeyPrefixesId: string
    

    SynchronizedKeyPrefixes Resource Properties

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

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The SynchronizedKeyPrefixes resource accepts the following input properties:

    DestinationPrefix string
    Destination key prefix to synchronize to.
    SourcePrefix string
    Source key prefix to synchronize from.
    Recurrence string
    SynchronizedKeyPrefixesId string
    The ID of this resource.
    DestinationPrefix string
    Destination key prefix to synchronize to.
    SourcePrefix string
    Source key prefix to synchronize from.
    Recurrence string
    SynchronizedKeyPrefixesId string
    The ID of this resource.
    destinationPrefix String
    Destination key prefix to synchronize to.
    sourcePrefix String
    Source key prefix to synchronize from.
    recurrence String
    synchronizedKeyPrefixesId String
    The ID of this resource.
    destinationPrefix string
    Destination key prefix to synchronize to.
    sourcePrefix string
    Source key prefix to synchronize from.
    recurrence string
    synchronizedKeyPrefixesId string
    The ID of this resource.
    destination_prefix str
    Destination key prefix to synchronize to.
    source_prefix str
    Source key prefix to synchronize from.
    recurrence str
    synchronized_key_prefixes_id str
    The ID of this resource.
    destinationPrefix String
    Destination key prefix to synchronize to.
    sourcePrefix String
    Source key prefix to synchronize from.
    recurrence String
    synchronizedKeyPrefixesId String
    The ID of this resource.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing SynchronizedKeyPrefixes Resource

    Get an existing SynchronizedKeyPrefixes 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?: SynchronizedKeyPrefixesState, opts?: CustomResourceOptions): SynchronizedKeyPrefixes
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            destination_prefix: Optional[str] = None,
            recurrence: Optional[str] = None,
            source_prefix: Optional[str] = None,
            synchronized_key_prefixes_id: Optional[str] = None) -> SynchronizedKeyPrefixes
    func GetSynchronizedKeyPrefixes(ctx *Context, name string, id IDInput, state *SynchronizedKeyPrefixesState, opts ...ResourceOption) (*SynchronizedKeyPrefixes, error)
    public static SynchronizedKeyPrefixes Get(string name, Input<string> id, SynchronizedKeyPrefixesState? state, CustomResourceOptions? opts = null)
    public static SynchronizedKeyPrefixes get(String name, Output<String> id, SynchronizedKeyPrefixesState state, CustomResourceOptions options)
    resources:  _:    type: etcd:SynchronizedKeyPrefixes    get:      id: ${id}
    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.
    The following state arguments are supported:
    DestinationPrefix string
    Destination key prefix to synchronize to.
    Recurrence string
    SourcePrefix string
    Source key prefix to synchronize from.
    SynchronizedKeyPrefixesId string
    The ID of this resource.
    DestinationPrefix string
    Destination key prefix to synchronize to.
    Recurrence string
    SourcePrefix string
    Source key prefix to synchronize from.
    SynchronizedKeyPrefixesId string
    The ID of this resource.
    destinationPrefix String
    Destination key prefix to synchronize to.
    recurrence String
    sourcePrefix String
    Source key prefix to synchronize from.
    synchronizedKeyPrefixesId String
    The ID of this resource.
    destinationPrefix string
    Destination key prefix to synchronize to.
    recurrence string
    sourcePrefix string
    Source key prefix to synchronize from.
    synchronizedKeyPrefixesId string
    The ID of this resource.
    destination_prefix str
    Destination key prefix to synchronize to.
    recurrence str
    source_prefix str
    Source key prefix to synchronize from.
    synchronized_key_prefixes_id str
    The ID of this resource.
    destinationPrefix String
    Destination key prefix to synchronize to.
    recurrence String
    sourcePrefix String
    Source key prefix to synchronize from.
    synchronizedKeyPrefixesId String
    The ID of this resource.

    Package Details

    Repository
    etcd ferlab-ste-justine/terraform-provider-etcd
    License
    Notes
    This Pulumi package is based on the etcd Terraform Provider.
    etcd logo
    etcd 0.10.0 published on Tuesday, Apr 15, 2025 by ferlab-ste-justine