alicloud.cs.RegistryEnterpriseSyncRule
Explore with Pulumi AI
This resource will help you to manager Container Registry Enterprise Edition sync rules.
For information about Container Registry Enterprise Edition sync rules and how to use it, see Create a Sync Rule
NOTE: Available since v1.90.0.
NOTE: You need to set your registry password in Container Registry Enterprise Edition console before use this resource.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "tf-example";
const source = new alicloud.cr.RegistryEnterpriseInstance("source", {
paymentType: "Subscription",
period: 1,
renewPeriod: 0,
renewalStatus: "ManualRenewal",
instanceType: "Advanced",
instanceName: `${name}-source`,
});
const target = new alicloud.cr.RegistryEnterpriseInstance("target", {
paymentType: "Subscription",
period: 1,
renewPeriod: 0,
renewalStatus: "ManualRenewal",
instanceType: "Advanced",
instanceName: `${name}-target`,
});
const sourceRegistryEnterpriseNamespace = new alicloud.cs.RegistryEnterpriseNamespace("source", {
instanceId: source.id,
name: name,
autoCreate: false,
defaultVisibility: "PUBLIC",
});
const targetRegistryEnterpriseNamespace = new alicloud.cs.RegistryEnterpriseNamespace("target", {
instanceId: target.id,
name: name,
autoCreate: false,
defaultVisibility: "PUBLIC",
});
const sourceRegistryEnterpriseRepo = new alicloud.cs.RegistryEnterpriseRepo("source", {
instanceId: source.id,
namespace: sourceRegistryEnterpriseNamespace.name,
name: name,
summary: "this is summary of my new repo",
repoType: "PUBLIC",
detail: "this is a public repo",
});
const targetRegistryEnterpriseRepo = new alicloud.cs.RegistryEnterpriseRepo("target", {
instanceId: target.id,
namespace: targetRegistryEnterpriseNamespace.name,
name: name,
summary: "this is summary of my new repo",
repoType: "PUBLIC",
detail: "this is a public repo",
});
const default = alicloud.getRegions({
current: true,
});
const defaultRegistryEnterpriseSyncRule = new alicloud.cs.RegistryEnterpriseSyncRule("default", {
instanceId: source.id,
namespaceName: sourceRegistryEnterpriseNamespace.name,
name: name,
targetRegionId: _default.then(_default => _default.regions?.[0]?.id),
targetInstanceId: target.id,
targetNamespaceName: targetRegistryEnterpriseNamespace.name,
tagFilter: ".*",
repoName: sourceRegistryEnterpriseRepo.name,
targetRepoName: targetRegistryEnterpriseRepo.name,
});
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "tf-example"
source = alicloud.cr.RegistryEnterpriseInstance("source",
payment_type="Subscription",
period=1,
renew_period=0,
renewal_status="ManualRenewal",
instance_type="Advanced",
instance_name=f"{name}-source")
target = alicloud.cr.RegistryEnterpriseInstance("target",
payment_type="Subscription",
period=1,
renew_period=0,
renewal_status="ManualRenewal",
instance_type="Advanced",
instance_name=f"{name}-target")
source_registry_enterprise_namespace = alicloud.cs.RegistryEnterpriseNamespace("source",
instance_id=source.id,
name=name,
auto_create=False,
default_visibility="PUBLIC")
target_registry_enterprise_namespace = alicloud.cs.RegistryEnterpriseNamespace("target",
instance_id=target.id,
name=name,
auto_create=False,
default_visibility="PUBLIC")
source_registry_enterprise_repo = alicloud.cs.RegistryEnterpriseRepo("source",
instance_id=source.id,
namespace=source_registry_enterprise_namespace.name,
name=name,
summary="this is summary of my new repo",
repo_type="PUBLIC",
detail="this is a public repo")
target_registry_enterprise_repo = alicloud.cs.RegistryEnterpriseRepo("target",
instance_id=target.id,
namespace=target_registry_enterprise_namespace.name,
name=name,
summary="this is summary of my new repo",
repo_type="PUBLIC",
detail="this is a public repo")
default = alicloud.get_regions(current=True)
default_registry_enterprise_sync_rule = alicloud.cs.RegistryEnterpriseSyncRule("default",
instance_id=source.id,
namespace_name=source_registry_enterprise_namespace.name,
name=name,
target_region_id=default.regions[0].id,
target_instance_id=target.id,
target_namespace_name=target_registry_enterprise_namespace.name,
tag_filter=".*",
repo_name=source_registry_enterprise_repo.name,
target_repo_name=target_registry_enterprise_repo.name)
package main
import (
"fmt"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cr"
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/cs"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "tf-example"
if param := cfg.Get("name"); param != "" {
name = param
}
source, err := cr.NewRegistryEnterpriseInstance(ctx, "source", &cr.RegistryEnterpriseInstanceArgs{
PaymentType: pulumi.String("Subscription"),
Period: pulumi.Int(1),
RenewPeriod: pulumi.Int(0),
RenewalStatus: pulumi.String("ManualRenewal"),
InstanceType: pulumi.String("Advanced"),
InstanceName: pulumi.String(fmt.Sprintf("%v-source", name)),
})
if err != nil {
return err
}
target, err := cr.NewRegistryEnterpriseInstance(ctx, "target", &cr.RegistryEnterpriseInstanceArgs{
PaymentType: pulumi.String("Subscription"),
Period: pulumi.Int(1),
RenewPeriod: pulumi.Int(0),
RenewalStatus: pulumi.String("ManualRenewal"),
InstanceType: pulumi.String("Advanced"),
InstanceName: pulumi.String(fmt.Sprintf("%v-target", name)),
})
if err != nil {
return err
}
sourceRegistryEnterpriseNamespace, err := cs.NewRegistryEnterpriseNamespace(ctx, "source", &cs.RegistryEnterpriseNamespaceArgs{
InstanceId: source.ID(),
Name: pulumi.String(name),
AutoCreate: pulumi.Bool(false),
DefaultVisibility: pulumi.String("PUBLIC"),
})
if err != nil {
return err
}
targetRegistryEnterpriseNamespace, err := cs.NewRegistryEnterpriseNamespace(ctx, "target", &cs.RegistryEnterpriseNamespaceArgs{
InstanceId: target.ID(),
Name: pulumi.String(name),
AutoCreate: pulumi.Bool(false),
DefaultVisibility: pulumi.String("PUBLIC"),
})
if err != nil {
return err
}
sourceRegistryEnterpriseRepo, err := cs.NewRegistryEnterpriseRepo(ctx, "source", &cs.RegistryEnterpriseRepoArgs{
InstanceId: source.ID(),
Namespace: sourceRegistryEnterpriseNamespace.Name,
Name: pulumi.String(name),
Summary: pulumi.String("this is summary of my new repo"),
RepoType: pulumi.String("PUBLIC"),
Detail: pulumi.String("this is a public repo"),
})
if err != nil {
return err
}
targetRegistryEnterpriseRepo, err := cs.NewRegistryEnterpriseRepo(ctx, "target", &cs.RegistryEnterpriseRepoArgs{
InstanceId: target.ID(),
Namespace: targetRegistryEnterpriseNamespace.Name,
Name: pulumi.String(name),
Summary: pulumi.String("this is summary of my new repo"),
RepoType: pulumi.String("PUBLIC"),
Detail: pulumi.String("this is a public repo"),
})
if err != nil {
return err
}
_default, err := alicloud.GetRegions(ctx, &alicloud.GetRegionsArgs{
Current: pulumi.BoolRef(true),
}, nil)
if err != nil {
return err
}
_, err = cs.NewRegistryEnterpriseSyncRule(ctx, "default", &cs.RegistryEnterpriseSyncRuleArgs{
InstanceId: source.ID(),
NamespaceName: sourceRegistryEnterpriseNamespace.Name,
Name: pulumi.String(name),
TargetRegionId: pulumi.String(_default.Regions[0].Id),
TargetInstanceId: target.ID(),
TargetNamespaceName: targetRegistryEnterpriseNamespace.Name,
TagFilter: pulumi.String(".*"),
RepoName: sourceRegistryEnterpriseRepo.Name,
TargetRepoName: targetRegistryEnterpriseRepo.Name,
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "tf-example";
var source = new AliCloud.CR.RegistryEnterpriseInstance("source", new()
{
PaymentType = "Subscription",
Period = 1,
RenewPeriod = 0,
RenewalStatus = "ManualRenewal",
InstanceType = "Advanced",
InstanceName = $"{name}-source",
});
var target = new AliCloud.CR.RegistryEnterpriseInstance("target", new()
{
PaymentType = "Subscription",
Period = 1,
RenewPeriod = 0,
RenewalStatus = "ManualRenewal",
InstanceType = "Advanced",
InstanceName = $"{name}-target",
});
var sourceRegistryEnterpriseNamespace = new AliCloud.CS.RegistryEnterpriseNamespace("source", new()
{
InstanceId = source.Id,
Name = name,
AutoCreate = false,
DefaultVisibility = "PUBLIC",
});
var targetRegistryEnterpriseNamespace = new AliCloud.CS.RegistryEnterpriseNamespace("target", new()
{
InstanceId = target.Id,
Name = name,
AutoCreate = false,
DefaultVisibility = "PUBLIC",
});
var sourceRegistryEnterpriseRepo = new AliCloud.CS.RegistryEnterpriseRepo("source", new()
{
InstanceId = source.Id,
Namespace = sourceRegistryEnterpriseNamespace.Name,
Name = name,
Summary = "this is summary of my new repo",
RepoType = "PUBLIC",
Detail = "this is a public repo",
});
var targetRegistryEnterpriseRepo = new AliCloud.CS.RegistryEnterpriseRepo("target", new()
{
InstanceId = target.Id,
Namespace = targetRegistryEnterpriseNamespace.Name,
Name = name,
Summary = "this is summary of my new repo",
RepoType = "PUBLIC",
Detail = "this is a public repo",
});
var @default = AliCloud.GetRegions.Invoke(new()
{
Current = true,
});
var defaultRegistryEnterpriseSyncRule = new AliCloud.CS.RegistryEnterpriseSyncRule("default", new()
{
InstanceId = source.Id,
NamespaceName = sourceRegistryEnterpriseNamespace.Name,
Name = name,
TargetRegionId = @default.Apply(@default => @default.Apply(getRegionsResult => getRegionsResult.Regions[0]?.Id)),
TargetInstanceId = target.Id,
TargetNamespaceName = targetRegistryEnterpriseNamespace.Name,
TagFilter = ".*",
RepoName = sourceRegistryEnterpriseRepo.Name,
TargetRepoName = targetRegistryEnterpriseRepo.Name,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cr.RegistryEnterpriseInstance;
import com.pulumi.alicloud.cr.RegistryEnterpriseInstanceArgs;
import com.pulumi.alicloud.cs.RegistryEnterpriseNamespace;
import com.pulumi.alicloud.cs.RegistryEnterpriseNamespaceArgs;
import com.pulumi.alicloud.cs.RegistryEnterpriseRepo;
import com.pulumi.alicloud.cs.RegistryEnterpriseRepoArgs;
import com.pulumi.alicloud.AlicloudFunctions;
import com.pulumi.alicloud.inputs.GetRegionsArgs;
import com.pulumi.alicloud.cs.RegistryEnterpriseSyncRule;
import com.pulumi.alicloud.cs.RegistryEnterpriseSyncRuleArgs;
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 config = ctx.config();
final var name = config.get("name").orElse("tf-example");
var source = new RegistryEnterpriseInstance("source", RegistryEnterpriseInstanceArgs.builder()
.paymentType("Subscription")
.period(1)
.renewPeriod(0)
.renewalStatus("ManualRenewal")
.instanceType("Advanced")
.instanceName(String.format("%s-source", name))
.build());
var target = new RegistryEnterpriseInstance("target", RegistryEnterpriseInstanceArgs.builder()
.paymentType("Subscription")
.period(1)
.renewPeriod(0)
.renewalStatus("ManualRenewal")
.instanceType("Advanced")
.instanceName(String.format("%s-target", name))
.build());
var sourceRegistryEnterpriseNamespace = new RegistryEnterpriseNamespace("sourceRegistryEnterpriseNamespace", RegistryEnterpriseNamespaceArgs.builder()
.instanceId(source.id())
.name(name)
.autoCreate(false)
.defaultVisibility("PUBLIC")
.build());
var targetRegistryEnterpriseNamespace = new RegistryEnterpriseNamespace("targetRegistryEnterpriseNamespace", RegistryEnterpriseNamespaceArgs.builder()
.instanceId(target.id())
.name(name)
.autoCreate(false)
.defaultVisibility("PUBLIC")
.build());
var sourceRegistryEnterpriseRepo = new RegistryEnterpriseRepo("sourceRegistryEnterpriseRepo", RegistryEnterpriseRepoArgs.builder()
.instanceId(source.id())
.namespace(sourceRegistryEnterpriseNamespace.name())
.name(name)
.summary("this is summary of my new repo")
.repoType("PUBLIC")
.detail("this is a public repo")
.build());
var targetRegistryEnterpriseRepo = new RegistryEnterpriseRepo("targetRegistryEnterpriseRepo", RegistryEnterpriseRepoArgs.builder()
.instanceId(target.id())
.namespace(targetRegistryEnterpriseNamespace.name())
.name(name)
.summary("this is summary of my new repo")
.repoType("PUBLIC")
.detail("this is a public repo")
.build());
final var default = AlicloudFunctions.getRegions(GetRegionsArgs.builder()
.current(true)
.build());
var defaultRegistryEnterpriseSyncRule = new RegistryEnterpriseSyncRule("defaultRegistryEnterpriseSyncRule", RegistryEnterpriseSyncRuleArgs.builder()
.instanceId(source.id())
.namespaceName(sourceRegistryEnterpriseNamespace.name())
.name(name)
.targetRegionId(default_.regions()[0].id())
.targetInstanceId(target.id())
.targetNamespaceName(targetRegistryEnterpriseNamespace.name())
.tagFilter(".*")
.repoName(sourceRegistryEnterpriseRepo.name())
.targetRepoName(targetRegistryEnterpriseRepo.name())
.build());
}
}
configuration:
name:
type: string
default: tf-example
resources:
source:
type: alicloud:cr:RegistryEnterpriseInstance
properties:
paymentType: Subscription
period: 1
renewPeriod: 0
renewalStatus: ManualRenewal
instanceType: Advanced
instanceName: ${name}-source
target:
type: alicloud:cr:RegistryEnterpriseInstance
properties:
paymentType: Subscription
period: 1
renewPeriod: 0
renewalStatus: ManualRenewal
instanceType: Advanced
instanceName: ${name}-target
sourceRegistryEnterpriseNamespace:
type: alicloud:cs:RegistryEnterpriseNamespace
name: source
properties:
instanceId: ${source.id}
name: ${name}
autoCreate: false
defaultVisibility: PUBLIC
targetRegistryEnterpriseNamespace:
type: alicloud:cs:RegistryEnterpriseNamespace
name: target
properties:
instanceId: ${target.id}
name: ${name}
autoCreate: false
defaultVisibility: PUBLIC
sourceRegistryEnterpriseRepo:
type: alicloud:cs:RegistryEnterpriseRepo
name: source
properties:
instanceId: ${source.id}
namespace: ${sourceRegistryEnterpriseNamespace.name}
name: ${name}
summary: this is summary of my new repo
repoType: PUBLIC
detail: this is a public repo
targetRegistryEnterpriseRepo:
type: alicloud:cs:RegistryEnterpriseRepo
name: target
properties:
instanceId: ${target.id}
namespace: ${targetRegistryEnterpriseNamespace.name}
name: ${name}
summary: this is summary of my new repo
repoType: PUBLIC
detail: this is a public repo
defaultRegistryEnterpriseSyncRule:
type: alicloud:cs:RegistryEnterpriseSyncRule
name: default
properties:
instanceId: ${source.id}
namespaceName: ${sourceRegistryEnterpriseNamespace.name}
name: ${name}
targetRegionId: ${default.regions[0].id}
targetInstanceId: ${target.id}
targetNamespaceName: ${targetRegistryEnterpriseNamespace.name}
tagFilter: .*
repoName: ${sourceRegistryEnterpriseRepo.name}
targetRepoName: ${targetRegistryEnterpriseRepo.name}
variables:
default:
fn::invoke:
Function: alicloud:getRegions
Arguments:
current: true
Create RegistryEnterpriseSyncRule Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new RegistryEnterpriseSyncRule(name: string, args: RegistryEnterpriseSyncRuleArgs, opts?: CustomResourceOptions);
@overload
def RegistryEnterpriseSyncRule(resource_name: str,
args: RegistryEnterpriseSyncRuleArgs,
opts: Optional[ResourceOptions] = None)
@overload
def RegistryEnterpriseSyncRule(resource_name: str,
opts: Optional[ResourceOptions] = None,
instance_id: Optional[str] = None,
namespace_name: Optional[str] = None,
tag_filter: Optional[str] = None,
target_instance_id: Optional[str] = None,
target_namespace_name: Optional[str] = None,
target_region_id: Optional[str] = None,
name: Optional[str] = None,
repo_name: Optional[str] = None,
target_repo_name: Optional[str] = None)
func NewRegistryEnterpriseSyncRule(ctx *Context, name string, args RegistryEnterpriseSyncRuleArgs, opts ...ResourceOption) (*RegistryEnterpriseSyncRule, error)
public RegistryEnterpriseSyncRule(string name, RegistryEnterpriseSyncRuleArgs args, CustomResourceOptions? opts = null)
public RegistryEnterpriseSyncRule(String name, RegistryEnterpriseSyncRuleArgs args)
public RegistryEnterpriseSyncRule(String name, RegistryEnterpriseSyncRuleArgs args, CustomResourceOptions options)
type: alicloud:cs:RegistryEnterpriseSyncRule
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 RegistryEnterpriseSyncRuleArgs
- 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 RegistryEnterpriseSyncRuleArgs
- 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 RegistryEnterpriseSyncRuleArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args RegistryEnterpriseSyncRuleArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args RegistryEnterpriseSyncRuleArgs
- 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 registryEnterpriseSyncRuleResource = new AliCloud.CS.RegistryEnterpriseSyncRule("registryEnterpriseSyncRuleResource", new()
{
InstanceId = "string",
NamespaceName = "string",
TagFilter = "string",
TargetInstanceId = "string",
TargetNamespaceName = "string",
TargetRegionId = "string",
Name = "string",
RepoName = "string",
TargetRepoName = "string",
});
example, err := cs.NewRegistryEnterpriseSyncRule(ctx, "registryEnterpriseSyncRuleResource", &cs.RegistryEnterpriseSyncRuleArgs{
InstanceId: pulumi.String("string"),
NamespaceName: pulumi.String("string"),
TagFilter: pulumi.String("string"),
TargetInstanceId: pulumi.String("string"),
TargetNamespaceName: pulumi.String("string"),
TargetRegionId: pulumi.String("string"),
Name: pulumi.String("string"),
RepoName: pulumi.String("string"),
TargetRepoName: pulumi.String("string"),
})
var registryEnterpriseSyncRuleResource = new RegistryEnterpriseSyncRule("registryEnterpriseSyncRuleResource", RegistryEnterpriseSyncRuleArgs.builder()
.instanceId("string")
.namespaceName("string")
.tagFilter("string")
.targetInstanceId("string")
.targetNamespaceName("string")
.targetRegionId("string")
.name("string")
.repoName("string")
.targetRepoName("string")
.build());
registry_enterprise_sync_rule_resource = alicloud.cs.RegistryEnterpriseSyncRule("registryEnterpriseSyncRuleResource",
instance_id="string",
namespace_name="string",
tag_filter="string",
target_instance_id="string",
target_namespace_name="string",
target_region_id="string",
name="string",
repo_name="string",
target_repo_name="string")
const registryEnterpriseSyncRuleResource = new alicloud.cs.RegistryEnterpriseSyncRule("registryEnterpriseSyncRuleResource", {
instanceId: "string",
namespaceName: "string",
tagFilter: "string",
targetInstanceId: "string",
targetNamespaceName: "string",
targetRegionId: "string",
name: "string",
repoName: "string",
targetRepoName: "string",
});
type: alicloud:cs:RegistryEnterpriseSyncRule
properties:
instanceId: string
name: string
namespaceName: string
repoName: string
tagFilter: string
targetInstanceId: string
targetNamespaceName: string
targetRegionId: string
targetRepoName: string
RegistryEnterpriseSyncRule 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 RegistryEnterpriseSyncRule resource accepts the following input properties:
- Instance
Id string - ID of Container Registry Enterprise Edition source instance.
- Namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- Tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- Target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- Target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- Target
Region stringId - The target region to be synchronized.
- Name string
- Name of Container Registry Enterprise Edition sync rule.
- Repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - Target
Repo stringName - Name of the target repository.
- Instance
Id string - ID of Container Registry Enterprise Edition source instance.
- Namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- Tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- Target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- Target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- Target
Region stringId - The target region to be synchronized.
- Name string
- Name of Container Registry Enterprise Edition sync rule.
- Repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - Target
Repo stringName - Name of the target repository.
- instance
Id String - ID of Container Registry Enterprise Edition source instance.
- namespace
Name String - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- tag
Filter String - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance StringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace StringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region StringId - The target region to be synchronized.
- name String
- Name of Container Registry Enterprise Edition sync rule.
- repo
Name String - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - target
Repo StringName - Name of the target repository.
- instance
Id string - ID of Container Registry Enterprise Edition source instance.
- namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region stringId - The target region to be synchronized.
- name string
- Name of Container Registry Enterprise Edition sync rule.
- repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - target
Repo stringName - Name of the target repository.
- instance_
id str - ID of Container Registry Enterprise Edition source instance.
- namespace_
name str - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- tag_
filter str - The regular expression used to filter image tags for synchronization in the source repository.
- target_
instance_ strid - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target_
namespace_ strname - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target_
region_ strid - The target region to be synchronized.
- name str
- Name of Container Registry Enterprise Edition sync rule.
- repo_
name str - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - target_
repo_ strname - Name of the target repository.
- instance
Id String - ID of Container Registry Enterprise Edition source instance.
- namespace
Name String - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- tag
Filter String - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance StringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace StringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region StringId - The target region to be synchronized.
- name String
- Name of Container Registry Enterprise Edition sync rule.
- repo
Name String - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - target
Repo StringName - Name of the target repository.
Outputs
All input properties are implicitly available as output properties. Additionally, the RegistryEnterpriseSyncRule resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- Sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- Sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.
- Id string
- The provider-assigned unique ID for this managed resource.
- Rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- Sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- Sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.
- id String
- The provider-assigned unique ID for this managed resource.
- rule
Id String - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction String FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope String REPO
orNAMESPACE
,the scope that the synchronization rule applies.
- id string
- The provider-assigned unique ID for this managed resource.
- rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.
- id str
- The provider-assigned unique ID for this managed resource.
- rule_
id str - The uuid of Container Registry Enterprise Edition sync rule.
- sync_
direction str FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync_
scope str REPO
orNAMESPACE
,the scope that the synchronization rule applies.
- id String
- The provider-assigned unique ID for this managed resource.
- rule
Id String - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction String FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope String REPO
orNAMESPACE
,the scope that the synchronization rule applies.
Look up Existing RegistryEnterpriseSyncRule Resource
Get an existing RegistryEnterpriseSyncRule 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?: RegistryEnterpriseSyncRuleState, opts?: CustomResourceOptions): RegistryEnterpriseSyncRule
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
instance_id: Optional[str] = None,
name: Optional[str] = None,
namespace_name: Optional[str] = None,
repo_name: Optional[str] = None,
rule_id: Optional[str] = None,
sync_direction: Optional[str] = None,
sync_scope: Optional[str] = None,
tag_filter: Optional[str] = None,
target_instance_id: Optional[str] = None,
target_namespace_name: Optional[str] = None,
target_region_id: Optional[str] = None,
target_repo_name: Optional[str] = None) -> RegistryEnterpriseSyncRule
func GetRegistryEnterpriseSyncRule(ctx *Context, name string, id IDInput, state *RegistryEnterpriseSyncRuleState, opts ...ResourceOption) (*RegistryEnterpriseSyncRule, error)
public static RegistryEnterpriseSyncRule Get(string name, Input<string> id, RegistryEnterpriseSyncRuleState? state, CustomResourceOptions? opts = null)
public static RegistryEnterpriseSyncRule get(String name, Output<String> id, RegistryEnterpriseSyncRuleState 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.
- Instance
Id string - ID of Container Registry Enterprise Edition source instance.
- Name string
- Name of Container Registry Enterprise Edition sync rule.
- Namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- Repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - Rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- Sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- Sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.- Tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- Target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- Target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- Target
Region stringId - The target region to be synchronized.
- Target
Repo stringName - Name of the target repository.
- Instance
Id string - ID of Container Registry Enterprise Edition source instance.
- Name string
- Name of Container Registry Enterprise Edition sync rule.
- Namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- Repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - Rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- Sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- Sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.- Tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- Target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- Target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- Target
Region stringId - The target region to be synchronized.
- Target
Repo stringName - Name of the target repository.
- instance
Id String - ID of Container Registry Enterprise Edition source instance.
- name String
- Name of Container Registry Enterprise Edition sync rule.
- namespace
Name String - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- repo
Name String - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - rule
Id String - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction String FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope String REPO
orNAMESPACE
,the scope that the synchronization rule applies.- tag
Filter String - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance StringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace StringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region StringId - The target region to be synchronized.
- target
Repo StringName - Name of the target repository.
- instance
Id string - ID of Container Registry Enterprise Edition source instance.
- name string
- Name of Container Registry Enterprise Edition sync rule.
- namespace
Name string - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- repo
Name string - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - rule
Id string - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction string FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope string REPO
orNAMESPACE
,the scope that the synchronization rule applies.- tag
Filter string - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance stringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace stringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region stringId - The target region to be synchronized.
- target
Repo stringName - Name of the target repository.
- instance_
id str - ID of Container Registry Enterprise Edition source instance.
- name str
- Name of Container Registry Enterprise Edition sync rule.
- namespace_
name str - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- repo_
name str - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - rule_
id str - The uuid of Container Registry Enterprise Edition sync rule.
- sync_
direction str FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync_
scope str REPO
orNAMESPACE
,the scope that the synchronization rule applies.- tag_
filter str - The regular expression used to filter image tags for synchronization in the source repository.
- target_
instance_ strid - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target_
namespace_ strname - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target_
region_ strid - The target region to be synchronized.
- target_
repo_ strname - Name of the target repository.
- instance
Id String - ID of Container Registry Enterprise Edition source instance.
- name String
- Name of Container Registry Enterprise Edition sync rule.
- namespace
Name String - Name of Container Registry Enterprise Edition source namespace. It can contain 2 to 30 characters.
- repo
Name String - Name of the source repository which should be set together with
target_repo_name
, if empty means that the synchronization scope is the entire namespace level. - rule
Id String - The uuid of Container Registry Enterprise Edition sync rule.
- sync
Direction String FROM
orTO
, the direction of synchronization.FROM
means source instance,TO
means target instance.- sync
Scope String REPO
orNAMESPACE
,the scope that the synchronization rule applies.- tag
Filter String - The regular expression used to filter image tags for synchronization in the source repository.
- target
Instance StringId - ID of Container Registry Enterprise Edition target instance to be synchronized.
- target
Namespace StringName - Name of Container Registry Enterprise Edition target namespace to be synchronized. It can contain 2 to 30 characters.
- target
Region StringId - The target region to be synchronized.
- target
Repo StringName - Name of the target repository.
Import
Container Registry Enterprise Edition sync rule can be imported using the id. Format to {instance_id}:{namespace_name}:{rule_id}
, e.g.
$ pulumi import alicloud:cs/registryEnterpriseSyncRule:RegistryEnterpriseSyncRule default `cri-xxx:my-namespace:crsr-yyy`
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.