cold-coat-35200
11/20/2018, 12:09 PMaws.elasticache.ReplicationGroup
, it looks like the cluster name will be the replicationGroupId
field value, which is not auto generated and a required field, because of this, when I changed the code, pulumi was unable to create the new resource first, because
aws:elasticache:ReplicationGroup (dlv-sbx-redis-ch):
error: Plan apply failed: Error creating Elasticache Replication Group: ReplicationGroupAlreadyExists: Replication group with specified name already exists.
status code: 400, request id: 4db05f24-ecb5-11e8-9c78-b503b112c20a
Is it possible to let pulumi handle the naming in this case too? Or maybe the deletetBeforeCreate
should be usedwhite-balloon-205
replicationGroupId
as a "name" property so that it gets autonamed.
Second, once https://github.com/pulumi/pulumi/issues/1620 is available (work in progress right now), you would have the option to add deleteBeforeCreate
here to unblock.
Third, and probably best right now - use the @pulumi/random
package to create your own random id:
let id = new random.RandomId('myid');
let storeGroup = new aws.elasticache.ReplicationGroup(storeGroupName, {
replicationGroupId: id,
});
That random ID will be generated once and stored in the checkpoint file between updates so that it will be the same across deployments of this stack, but different across different stacks.cold-coat-35200
11/20/2018, 4:18 PMwhite-balloon-205
cold-coat-35200
11/20/2018, 4:27 PM