如何向AWS CloudFormation提供非字母数字参数类型?

问题描述 投票:1回答:1

嗨,我正在从 CLI 创建一个 CloudFormation 堆栈,并试图提供一个 url 参数。我给的类型是 String 因为我找不到任何关于URL的具体内容。这里

问题是,当我把它作为 Type: String我得到这个错误。

An error occurred (ValidationError) when calling the CreateStack operation: Template format error: Parameter name TELEPHONY_URL is non alphanumeric.

这是我的参数json。

{ "ParameterKey": "TELEPHONY_URL", "ParameterValue": "https://telephony.crm4b2c.com/1/api/Telephony/LogCallComplete/" }

请帮助我。

amazon-web-services amazon-cloudformation
1个回答
1
投票

问题是,参数名称 TELEPHONY_URL 必须是字母数字,不能有特殊字符。

所以可以尝试更新它,例如 TELEPHONYURLTelephonyURL


1
投票

而不是在部署时一个一个地遇到这些错误,而是在部署时一个一个地出现。CloudForm LinterCloudFormation Linter Visual Studio代码扩展 在处理CloudFormation模板时,可以在线显示这些错误。

E2003 Parameter TELEPHONY_URL has invalid name.  Name has to be alphanumeric.

CloudFormation Linter Visual Studio Code extension screenshot

© www.soinside.com 2019 - 2024. All rights reserved.