Github动作参数在模板中找不到



尝试使用github动作将基础设施从CDK移回Cloudformation模板

我正在使用github动作aw -cloudformation-github-deploy

- name: Deploy to AWS CloudFormation
uses: aws-actions/aws-cloudformation-github-deploy@v1
with:
name: service-name
template: stack.yaml
parameter-overrides: "Env=stg"

堆栈。从CDK生成的yaml代码段

AWSTemplateFormatVersion: '2010-09-09'
Description: Accounts API Infrastructure
Parameters:
Env:
Description: Environment to be deployed
Type: String

Resources:
SecurityGroupA0B2798B:
Type: AWS::EC2::SecurityGroup

我不断得到Parameters: [Env] do not exist in the template,即使它在堆栈模板中看到。

还将参数添加到原始CDK部署

下面是一个来自GitHub Action的例子

- name: Deploy with AWS CloudFormation
uses: aws-actions/aws-cloudformation-github-deploy@v1
with:
name: service-name
template: stack.yaml
parameter-overrides: >-
FirstParameter=stg,            
SecondParameter=something

相关内容

最新更新