busy-toothbrush-90194
11/07/2023, 12:05 PMpulumi stack init --secrets-provider="<awskms://alias/kms?region=us-west-2>" --stack org-name/stack-name
but getting error: organization name must be 'organization'
can anyone explain what's causing this error?fierce-night-38522
11/07/2023, 12:28 PM--secrets-provider
flag, does it still give the same error?busy-toothbrush-90194
11/07/2023, 1:37 PMv3.82.0
fierce-night-38522
11/07/2023, 1:40 PMv3.92.0
. I would recommend updating Pulumi in your environment to start and try again.
If you still get the same error, then we'd probably have to look into your S3 backend configuration I'm thinkingbusy-toothbrush-90194
11/07/2023, 1:43 PM--default-org string A default org to associate with the login. Please note, currently, only the managed and self-hosted backends support organizations
proud-pizza-80589
11/07/2023, 1:44 PMbusy-toothbrush-90194
11/07/2023, 1:44 PMorganization
with non pulumi cloud backend?proud-pizza-80589
11/07/2023, 1:48 PMbusy-toothbrush-90194
11/07/2023, 1:51 PMorg-name/stack-name
but with s3 it is just the stack-name
. In s3 realm org name won't be as relevant as in Pulumi cloud but it would have been nice to keep the stack name the same post migration.proud-pizza-80589
11/07/2023, 1:54 PM#!/bin/bash -x
export PULUMI_ACCESS_TOKEN="pul-xxx"
export PULUMI_CONFIG_PASSPHRASE=xxx
rm -Rf Pulumi.yaml Pulumi.*.yaml
echo "name: bpaas" > Pulumi.yaml
echo "runtime: nodejs" >> Pulumi.yaml
pulumi logout
pulumi login
STACKS=$(pulumi stack ls -j | jq -r ".[].name" | sed "s/settlemint\///" | grep 'staging-')
while read -r stack; do
echo "Migrating stack ${stack}"
pulumi logout
pulumi login
pulumi stack select settlemint/bpaas/${stack}
pulumi stack change-secrets-provider "<awskms://alias/xxx-xxx-xxx?region=eu-central-1>"
pulumi stack export --show-secrets --file ${stack}.json
pulumi stack change-secrets-provider default
pulumi logout
pulumi login '<s3://xxx-xxx-xxx?region=eu-central-1>'
pulumi stack init ${stack} || pulumi stack select organization/bpaas/${stack}
cat ${stack}.json | sed 's/settlemint\/bpaas-clusters/organization\/bpaas-clusters/g' > ${stack}-replaced.json
pulumi stack import --file ${stack}-replaced.json
pulumi refresh --yes
done <<< "$STACKS"
busy-toothbrush-90194
11/07/2023, 2:46 PMproud-pizza-80589
11/07/2023, 2:51 PM