Visualising CloudFormation Stack

Visualising CloudFormation Stack

If you work with AWS CloudFormation on a day-to-day basis, I think you might be interested in visualising your AWS CloudFormation templates. CloudFormation stack visualization can be quite handy for lifecycle management of your AWS deployment. In addition, visualization can be immensely helpful in change management and governance.

Visualizing CloudFormation Templates using Graphviz

cloud-formation-viz is a Graphviz based script which takes your CloudForamtion template as input and creates the visualisation. This script requires Python and Graphviz pre-installed.

cat example.template | ./cfviz | dot -Tsvg -oexample.svg

Visualizing CloudFormation Templates using Graphviz


Alternatively, you can use VisualOps to visualise your current AWS stack. VisualOps creates more structured and high-resolution diagrams for your AWS stack and visualisation is one of the many features offered by VisualOps. Using VisualOps, you can either import your existing CloudFormation template to generate the diagram automatically or create AWS CloudFormation templates by utilising a WYSIWYG editor.

Visualization of Apache Mesos CloudFormation Stack using VisualOps

CloudFormation Designer

Since I wrote this post, AWS has released the CloudFormation Designer which allows one to create and modify CloudFormation templates using a drag-and-drop interface. With this new feature, one can view the contents of any valid AWS CloudFormation template as a diagram and relationship between various AWS resources.

CloudFormation Designer

Unlike VisualOps, CloudFormation Designer requires a very good understanding of the AWS resources that you want include in your template. On positive side, CloudFormation Designer includes a tabbed JSON editor interface to interact with template components. Tabbed JSON editor provides an auto-complete feature for resource property names. I was really impressed with validation part. For instance, you cannot add an EC2 instance directly inside a VPC unless you create a subnet in the VPC and add the instance to subnet.

CloudFormation Designer

Last but not least, now you can reverse engineer CloudFormation templates from your existing resources using the CloudFormer utility. How handy is that!


Abhishek Tiwari

Abhishek Tiwari is a hands-on technologist and an engineering leader with a polymath background. He writes about technology, architecture, and engineering leadership.

View Comments
Next Post

Rethinking the database with drop-in replacements

Previous Post

DynamoDB or Aurora