refined-plastic-19043
10/12/2023, 12:35 PMvar regions = new []
{
new { Name = "ireland", Region = "eu-west-1" },
new { Name = "north-virginia", Region = "us-east-1" },
};
foreach (var region in regions)
{
var nativeProvider = new PulumiNative.Provider(region.Name, new PulumiNative.ProviderArgs
{
Region = region.Region,
}, new CustomResourceOptions
{
Aliases = new List<Input<Alias>>
{
new Alias
{
Urn = "urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::default_0_75_0", // that's the existing provider that I want to rename
},
},
});
}
Above code, according to the comment from the issue, should work but it just throws following error:
`error: Duplicate resource URN 'urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::default_0_75_0' conflicting with alias on resource with URN 'urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::ireland'
(full diff below)
'dotnet build -nologo .' completed successfully
pulumi:pulumi:Stack: (same)
[urn=urn:pulumi:development::AWS.Infrastructure::pulumi:pulumi:Stack::AWS.Infrastructure-development]
error: Duplicate resource URN 'urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::default_0_75_0' conflicting with alias on resource with URN 'urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::ireland'
~ pulumi:providers:aws-native: (update)
[id=316643b1-d250-4441-b043-f54a9a592a04]
[urn=urn:pulumi:development::AWS.Infrastructure::pulumi:providers:aws-native::ireland]
region : "eu-west-1"
+ skipCredentialsValidation: "true"
+ skipGetEc2Platforms : "true"
+ skipMetadataApiCheck : "true"
+ skipRegionValidation : "true"
version : "0.75.0"
Resources:
~ 1 to update
1 unchanged