我有下面的循环词模板,我使用从一个教程。
jobs:
create_infrastructure:
docker:
- image: amazon/aws-cli
steps:
- checkout
- run:
name: Ensure backend infrastructure exist
command: |
aws cloudformation deploy \
--template-file template.yml \
--stack-name my-stack
workflows:
my_workflow:
jobs:
- create_infrastructure但是当我在循环中执行时,我得到了
You must specify a region. You can also configure your region by running "aws configure".
Exited with code exit status 253请帮我排除疑难。

还尝试将env vars添加到圆形区域,如截图中所示。

发布于 2021-02-22 06:25:18
正如错误信息所暗示的那样。您需要将区域添加到配置中:
jobs:
create_infrastructure:
docker:
- image: amazon/aws-cli
steps:
- checkout
- run:
name: Ensure backend infrastructure exist
command: |
aws cloudformation deploy \
--template-file template.yml \
--stack-name my-stack \
--region <your-region, e.g. us-east-1>
workflows:
my_workflow:
jobs:
- create_infrastructure更新
在一行(而不是多行)中使用命令是解决方案:
aws cloudformation deploy --template-file template.yml --stack-name my-stack --region eu-central-1https://stackoverflow.com/questions/66310734
复制相似问题