great-sunset-355
05/01/2024, 6:05 AMdependsOn
not respect the delete order?
I attached a local command to the IAM user but removing the code and then pulumi up
will attempt to delete iamUser
before running the command. 🤷
const userName = "myUser"
const cleanupCmd = new command.local.Command(
`delete-iam-user`,
{
environment: {
IAM_USERNAME: userName,
},
delete: `date && node --require ts-node/register delete-iam-user.ts`,
// triggers: [md5],
},
);
// cleanupCmd.apply(console.log);
const iamUser = new aws.iam.User(
`user`,{name: userName},
{ dependsOn: cleanupCmd}
);
this is with pulumi 3.112.0
ancient-car-89914
05/01/2024, 7:03 AMancient-car-89914
05/01/2024, 7:04 AMgreat-sunset-355
05/01/2024, 7:27 AMancient-car-89914
05/01/2024, 7:30 AMgreat-sunset-355
05/01/2024, 7:33 AM