We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi
We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi
The AWS::ECR::ReplicationConfiguration resource creates or updates the replication configuration for a private registry. The first time a replication configuration is applied to a private registry, a service-linked IAM role is created in your account for the replication process. For more information, see Using Service-Linked Roles for Amazon ECR in the Amazon Elastic Container Registry User Guide.
When configuring cross-account replication, the destination account must grant the source account permission to replicate. This permission is controlled using a private registry permissions policy. For more information, see AWS::ECR::RegistryPolicy.
Example Usage
Example
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AwsNative = Pulumi.AwsNative;
return await Deployment.RunAsync(() =>
{
var myReplicationConfig = new AwsNative.Ecr.ReplicationConfiguration("myReplicationConfig", new()
{
ReplicationConfigurationValue = new AwsNative.Ecr.Inputs.ReplicationConfigurationArgs
{
Rules = new[]
{
new AwsNative.Ecr.Inputs.ReplicationConfigurationReplicationRuleArgs
{
Destinations = new[]
{
new AwsNative.Ecr.Inputs.ReplicationConfigurationReplicationDestinationArgs
{
Region = "us-east-2",
RegistryId = "123456789012",
},
new AwsNative.Ecr.Inputs.ReplicationConfigurationReplicationDestinationArgs
{
Region = "us-west-1",
RegistryId = "123456789012",
},
},
},
},
},
});
});
package main
import (
"github.com/pulumi/pulumi-aws-native/sdk/go/aws/ecr"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ecr.NewReplicationConfiguration(ctx, "myReplicationConfig", &ecr.ReplicationConfigurationArgs{
ReplicationConfiguration: &ecr.ReplicationConfigurationTypeArgs{
Rules: ecr.ReplicationConfigurationReplicationRuleArray{
&ecr.ReplicationConfigurationReplicationRuleArgs{
Destinations: ecr.ReplicationConfigurationReplicationDestinationArray{
&ecr.ReplicationConfigurationReplicationDestinationArgs{
Region: pulumi.String("us-east-2"),
RegistryId: pulumi.String("123456789012"),
},
&ecr.ReplicationConfigurationReplicationDestinationArgs{
Region: pulumi.String("us-west-1"),
RegistryId: pulumi.String("123456789012"),
},
},
},
},
},
})
if err != nil {
return err
}
return nil
})
}
Example coming soon!
Example coming soon!
import * as pulumi from "@pulumi/pulumi";
import * as aws_native from "@pulumi/aws-native";
const myReplicationConfig = new aws_native.ecr.ReplicationConfiguration("myReplicationConfig", {replicationConfiguration: {
rules: [{
destinations: [
{
region: "us-east-2",
registryId: "123456789012",
},
{
region: "us-west-1",
registryId: "123456789012",
},
],
}],
}});
import pulumi
import pulumi_aws_native as aws_native
my_replication_config = aws_native.ecr.ReplicationConfiguration("myReplicationConfig", replication_configuration={
"rules": [{
"destinations": [
{
"region": "us-east-2",
"registry_id": "123456789012",
},
{
"region": "us-west-1",
"registry_id": "123456789012",
},
],
}],
})
Example coming soon!
Create ReplicationConfiguration Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new ReplicationConfiguration(name: string, args: ReplicationConfigurationArgs, opts?: CustomResourceOptions);@overload
def ReplicationConfiguration(resource_name: str,
args: ReplicationConfigurationInitArgs,
opts: Optional[ResourceOptions] = None)
@overload
def ReplicationConfiguration(resource_name: str,
opts: Optional[ResourceOptions] = None,
replication_configuration: Optional[ReplicationConfigurationArgs] = None)func NewReplicationConfiguration(ctx *Context, name string, args ReplicationConfigurationArgs, opts ...ResourceOption) (*ReplicationConfiguration, error)public ReplicationConfiguration(string name, ReplicationConfigurationArgs args, CustomResourceOptions? opts = null)
public ReplicationConfiguration(String name, ReplicationConfigurationArgs args)
public ReplicationConfiguration(String name, ReplicationConfigurationArgs args, CustomResourceOptions options)
type: aws-native:ecr:ReplicationConfiguration
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
resource "aws-native_ecr_replication_configuration" "name" {
# resource properties
}Parameters
- name string
- The unique name of the resource.
- args ReplicationConfigurationArgs
- 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 ReplicationConfigurationInitArgs
- 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 ReplicationConfigurationArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ReplicationConfigurationArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ReplicationConfigurationArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
ReplicationConfiguration 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 ReplicationConfiguration resource accepts the following input properties:
- Replication
Configuration Pulumi.Value Aws Native. Ecr. Inputs. Replication Configuration - The replication configuration for a registry.
- Replication
Configuration ReplicationConfiguration Type Args - The replication configuration for a registry.
- replication_
configuration object - The replication configuration for a registry.
- replication
Configuration ReplicationConfiguration - The replication configuration for a registry.
- replication
Configuration ReplicationConfiguration - The replication configuration for a registry.
- replication_
configuration ReplicationConfiguration Args - The replication configuration for a registry.
- replication
Configuration Property Map - The replication configuration for a registry.
Outputs
All input properties are implicitly available as output properties. Additionally, the ReplicationConfiguration resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Registry
Id string - The account ID of the destination registry.
- Id string
- The provider-assigned unique ID for this managed resource.
- Registry
Id string - The account ID of the destination registry.
- id string
- The provider-assigned unique ID for this managed resource.
- registry_
id string - The account ID of the destination registry.
- id String
- The provider-assigned unique ID for this managed resource.
- registry
Id String - The account ID of the destination registry.
- id string
- The provider-assigned unique ID for this managed resource.
- registry
Id string - The account ID of the destination registry.
- id str
- The provider-assigned unique ID for this managed resource.
- registry_
id str - The account ID of the destination registry.
- id String
- The provider-assigned unique ID for this managed resource.
- registry
Id String - The account ID of the destination registry.
Look up Existing ReplicationConfiguration Resource
Get an existing ReplicationConfiguration 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>, opts?: CustomResourceOptions): ReplicationConfiguration@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None) -> ReplicationConfigurationfunc GetReplicationConfiguration(ctx *Context, name string, id IDInput, state *ReplicationConfigurationState, opts ...ResourceOption) (*ReplicationConfiguration, error)public static ReplicationConfiguration Get(string name, Input<string> id, CustomResourceOptions? opts = null)public static ReplicationConfiguration get(String name, Output<String> id, CustomResourceOptions options)resources: existingReplicationConfiguration: type: aws-native:ecr:ReplicationConfiguration get: id: ${id}import {
to = aws-native_ecr_replication_configuration.example
id = "${id}"
}
- name string
- The unique name of the resulting resource.
- id Input<ID>
- The unique provider ID of the resource to look up.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resulting resource.
- id str
- The unique provider ID of the resource to look up.
- 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 resulting resource.
- id IDInput
- The unique provider ID of the resource to look up.
- state ReplicationConfigurationState
- Pass nil. This resource has no state arguments.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resulting resource.
- id Input<string>
- The unique provider ID of the resource to look up.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resulting resource.
- id Output<String>
- The unique provider ID of the resource to look up.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Supporting Types
ReplicationConfiguration, ReplicationConfigurationArgs
The replication configuration for a registry.
- Rules
List<Pulumi.
Aws Native. Ecr. Inputs. Replication Configuration Replication Rule> - An array of objects representing the replication destinations and repository filters for a replication configuration.
- Rules
[]Replication
Configuration Replication Rule - An array of objects representing the replication destinations and repository filters for a replication configuration.
- rules list(object)
- An array of objects representing the replication destinations and repository filters for a replication configuration.
- rules
List<Replication
Configuration Replication Rule> - An array of objects representing the replication destinations and repository filters for a replication configuration.
- rules
Replication
Configuration Replication Rule[] - An array of objects representing the replication destinations and repository filters for a replication configuration.
- rules
Sequence[Replication
Configuration Replication Rule] - An array of objects representing the replication destinations and repository filters for a replication configuration.
- rules List<Property Map>
- An array of objects representing the replication destinations and repository filters for a replication configuration.
ReplicationConfigurationDeleteReplication, ReplicationConfigurationDeleteReplicationArgs
- Enabled bool
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- Enabled bool
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- enabled bool
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- enabled Boolean
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- enabled boolean
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- enabled bool
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
- enabled Boolean
- Whether image deletions and image tag removals in the source registry are replicated to the replication destinations.
ReplicationConfigurationFilterType
Type of repository filter
| Name | Value |
|---|---|
| Prefix | PREFIX_MATCH |
| Name | Value |
|---|---|
| Replication | PREFIX_MATCH |
| Value |
|---|
PREFIX_MATCH |
| Name | Value |
|---|---|
| Prefix | PREFIX_MATCH |
| Name | Value |
|---|---|
| Prefix | PREFIX_MATCH |
| Name | Value |
|---|---|
| PREFIX_MATCH | PREFIX_MATCH |
| Value |
|---|
PREFIX_MATCH |
ReplicationConfigurationReplicationDestination, ReplicationConfigurationReplicationDestinationArgs
An array of objects representing the destination for a replication rule.
- Region string
- The Region to replicate to.
- Registry
Id string - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- Region string
- The Region to replicate to.
- Registry
Id string - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- region string
- The Region to replicate to.
- registry_
id string - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- region String
- The Region to replicate to.
- registry
Id String - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- region string
- The Region to replicate to.
- registry
Id string - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- region str
- The Region to replicate to.
- registry_
id str - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
- region String
- The Region to replicate to.
- registry
Id String - The AWS account ID of the Amazon ECR private registry to replicate to. When configuring cross-Region replication within your own registry, specify your own account ID.
ReplicationConfigurationReplicationRule, ReplicationConfigurationReplicationRuleArgs
An array of objects representing the replication destinations and repository filters for a replication configuration.
- Destinations
List<Pulumi.
Aws Native. Ecr. Inputs. Replication Configuration Replication Destination> - An array of objects representing the destination for a replication rule.
- Delete
Replication Pulumi.Aws Native. Ecr. Inputs. Replication Configuration Delete Replication - Repository
Filters List<Pulumi.Aws Native. Ecr. Inputs. Replication Configuration Repository Filter> - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- Destinations
[]Replication
Configuration Replication Destination - An array of objects representing the destination for a replication rule.
- Delete
Replication ReplicationConfiguration Delete Replication - Repository
Filters []ReplicationConfiguration Repository Filter - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- destinations list(object)
- An array of objects representing the destination for a replication rule.
- delete_
replication object - repository_
filters list(object) - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- destinations
List<Replication
Configuration Replication Destination> - An array of objects representing the destination for a replication rule.
- delete
Replication ReplicationConfiguration Delete Replication - repository
Filters List<ReplicationConfiguration Repository Filter> - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- destinations
Replication
Configuration Replication Destination[] - An array of objects representing the destination for a replication rule.
- delete
Replication ReplicationConfiguration Delete Replication - repository
Filters ReplicationConfiguration Repository Filter[] - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- destinations
Sequence[Replication
Configuration Replication Destination] - An array of objects representing the destination for a replication rule.
- delete_
replication ReplicationConfiguration Delete Replication - repository_
filters Sequence[ReplicationConfiguration Repository Filter] - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
- destinations List<Property Map>
- An array of objects representing the destination for a replication rule.
- delete
Replication Property Map - repository
Filters List<Property Map> - An array of objects representing the filters for a replication rule. Specifying a repository filter for a replication rule provides a method for controlling which repositories in a private registry are replicated.
ReplicationConfigurationRepositoryFilter, ReplicationConfigurationRepositoryFilterArgs
The filter settings used with image replication. Specifying a repository filter to a replication rule provides a method for controlling which repositories in a private registry are replicated. If no filters are added, the contents of all repositories are replicated.
- Filter string
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - Filter
Type Pulumi.Aws Native. Ecr. Replication Configuration Filter Type - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- Filter string
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - Filter
Type ReplicationConfiguration Filter Type - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- filter string
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - filter_
type "PREFIX_MATCH" - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- filter String
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - filter
Type ReplicationConfiguration Filter Type - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- filter string
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - filter
Type ReplicationConfiguration Filter Type - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- filter str
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - filter_
type ReplicationConfiguration Filter Type - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
- filter String
- The repository filter details. When the
PREFIX_MATCHfilter type is specified, this value is required and should be the repository name prefix to configure replication for. - filter
Type "PREFIX_MATCH" - The repository filter type. The only supported value is
PREFIX_MATCH, which is a repository name prefix specified with thefilterparameter.
Package Details
- Repository
- AWS Native pulumi/pulumi-aws-native
- License
- Apache-2.0
We recommend new projects start with resources from the AWS provider.
published on Wednesday, Nov 18, 2026 by Pulumi