export AWS_PROFILE=88HoursDevOps
aws configure sso --profile 88HoursDevOps # rm -rf ~/.aws/sso/cache
## Terrible issues https://github.com/aws/aws-cli/issues/5057
## sso_role_name = SSODeveloperPermissionSet
SSO session name (Recommended): devops
SSO start URL [None]: https://88hours.awsapps.com/start/
SSO region [None]: ap-southeast-2
SSO registration scopes [sso:account:access]:
aws sso login --profile 88HoursDevOps
aws sts get-caller-identity --profile 88HoursDevOps
aws iam get-role --role-name ecsTaskExecutionRole --query 'Role.Arn' --output text
aws sso logout
## Create S3 Backend for state locking
aws s3api create-bucket \
--bucket devops-terraform-state-bucket-88hours \
--region ap-southeast-2 \
--create-bucket-configuration LocationConstraint=ap-southeast-2 \
--profile 88HoursDevOps
terraform init -backend-config=backend.config