简体   繁体   English

Cloudformation模板到SAM还是无服务器?

[英]Cloudformation template to SAM or serverless?

I want to extend lambCI cloudformation template but am finding myself lost in barley human-readable json/yml it provides. 我想扩展lambCI cloudformation模板,但是发现自己迷失在它提供的大麦人类可读json / yml中。

Is it possible to reverse-transform CF template to something else(sam, serverless...), edit it and then transform back? 是否可以将CF模板反向转换为其他模板(SAM,无服务器...),对其进行编辑然后再转换回去?

That template is not really complicated. 该模板并不是很复杂。 Having it as a SAM-template wouldn't make it more readable at all, because the ressources it defines either can't be defined using SAM or wouldn't make it significantly shorter. 将其作为SAM模板根本不会使其更具可读性,因为它定义的资源要么无法使用SAM定义,要么不会使其明显缩短。

As far as I know there are also no tools available which would do conversion to SAM/Serverless automatically. 据我所知,也没有可用的工具可以自动转换为SAM / Serverless。

I always find such templates way more readable in YAML, than in JSON, so what you could do is to convert it from JSON to YAML using aws-cfn-template-flip , edit it and convert it back afterwards (or even use it as YAML). 我总是发现这样的模板在YAML中比在JSON中更具可读性,因此您可以使用aws-cfn-template-flip将其从JSON转换为YAML,对其进行编辑并随后将其转换回(或者甚至将其用作YAML)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM