AWS CloudFormation Diagrams 0.3.0 is out!

AWS CloudFormation Diagrams is an open source tool to generate AWS infrastructure diagrams from AWS CloudFormation templates.

It parses both YAML and JSON AWS CloudFormation templates, supports 159 AWS resource types and any custom resource types, supports Rain::Module resource type, supports DependsOn, Ref, Fn::GetAtt relationships, and ${} resource attributes, generates D2, DOT, draw.io, GIF, JPEG, Mermaid, PDF, PNG, SVG, and TIFF diagrams, provides highly configurable visual representation, D2 Diagram Generation, Mermaid Diagram Generation, provides an interactive diagram viewer, allows editable draw.io export, and provides 156 generated diagram examples.

This new release comes with many improvements and is available as a Python package in PyPI.

Following illustrates some generated diagrams


Related discussions:

Which do you use - Terraform or CloudFormation?
Cloudformation/Ansible for declarative infrastructure. Where to put other imperative and stateful logic like blue/green deployments and rollbacks?
Necessary Skills for AWS Solutions Architect
Pedant alert - Cloudformation yaml convention to not indent children
AWS CloudFormation, Swagger, and Broken Dreams
CloudFormation String Help
Providing secure access to S3 buckets for applications
AWS Architecture Icons Updated
Service Catalog - Good and Bad Stories Wanted
Which tech stack(s) is AWS built on?
How to incorporate existing infrastructure into a Cloudformation Stack?
How do you organise your CloudFormation templates?
Jinja2 tutorial
Anybody using Amplify CLI in production? What is your experience so far and how to deal with the messy resources that are created?
Cloudformation : What visual JSON editor(s) do you use?
Anyway to tag nodes in ASG set differently in CloudFormation?
Does a Lambda function invocation download the zip file from S3 on every run?
General Question - Architecture
I wonder if AWS beginners should be introduced to the CDK as a primary method of manipulating resources in the AWS cloud and demote the web console to a secondary tool used for reviewing what you have running?
We are the AWS CDK Team - Ask the Experts - Jan 27th @ 10AM PT / 1PM ET / 6PM GMT!
What is the best tool for managing CloudFormation stacks with CLI?
AWS just released an official AWS Quick Start
HPC on AWS
AWS Documentation (2021)
Having trouble following the Cloudformation guide to setting up a static site. Failed several times in certificate creation. Willing to hire someone to walk me through it.
Cloudformation Resources Questions
Automatically clean up stacks on cloudformation
Where can I find architecture practice tests or problems to solve?
Graphics tablets for architecture
Learning How To CFN, common scenarios
AWS outage? (2022)
AWS Architecture Diagram tool recommendations
mobile architecture help
Deployment via cloudFormation
What to look into next, given cloudformation is telling me my aws::ecs::service timed out while trying to complete.
How do you manage a lot of CDK stacks?
How's CloudFormation StackSets treating everyone these days?
Best Way to Organize AWS Resources for Prod / Development / "Experimental"?
Do you use CDK context?
How did you transition into IaC?
Which tool is used to make deployment diagrams animated?
How are CloudFormation nested stacks these days?
AWS Issues (2016)
What are your thoughts on browser extensions for AWS?
Experience up to 40% faster stack creation with AWS CloudFormation
Is lambda layers the right approach to this problem?
Is there an easier way to convert existing environment to code?
Processing a bunch of financial documents, architecture suggestings?
Seeking feedback on multi-repo, environment-based infra and schema management approach for my SaaS
Terraform vs CloudFormation (2024-12-14)
Is EC2 AMI+autoscaling good enough, or should I try something else?
Moving to CloudFormation with Terraform/Terragrunt background, having difficulties
Infrastructure as Software: Beyond Infrastructure as Code
how bad is it to launch without a proper cloud architecture plan?
More common mistakes to avoid when creating system architecture diagrams
Cloud architecture option A vs option B, how do you compare them with real numbers?
Architecture job after getting certified?
Warm Standby vs Pilot Light
Cloud Architecture & Design Practice Questions
Replicate data from on-premise Oracle DB to AWS Cloud.
Machine Learning Cert Practice?
Data Analytics study path for a big data noob?
Automated-Cloud-Advisor
I recently got my AWS SAA certification, however, I feel like my actual experience with AWS is limited
Labs demonstrating High Availability and/or Fault Tolerant architecture
Real architecture experience
Job requirements
Passed SAA-C03 Thoughs, Tipps, Ressources and Thank You
Next step after obtaining developer associate certification
Thoughts on AWS Skill Builder courses as preparation for Solutions Architecture Associate?
Taking the PAS-C01 (SAP on AWS) Specialty. Are there any good resources?
Opsworks EOL in Devops exam
Trying to pass "solution architect" by my own
Passed DVA-CO2
Serverless Developer - New Level on Free Architecture Game - Card Clash
Architecture professional vs Security Specialty
What general Architecture would you recommend
AWS CloudFormation Update -€“ YAML, Cross-Stack References, Simplified Substitution
How to pass and store environment variables in ec2 instances with CloudFormation
CloudFormation Version Control
Understanding Nested CloudFormation Stacks
Are you worried using AWS specific tools which aren't on other clouds will make you too dependent?
CloudFormation, Route53, GovCloud
CloudFormation Now Supports Managed NAT Gateway
Questions about the basics of elastic beanstalk.
Cloudformation - making RDS not publicly accessible without recreating resource.
Quick Question about AMIs and private IPs!
IAM policy to allow changes only through CloudFormation?
CF timing out when adding environment variables to Lambda function
Vaporshell 1.0.0 released - CloudFormation template DSL for Powershell - Full AWS coverage
What does your high level CloudFormation setup look like?
Making an AWS budget
CloudFormation: Any way to export values from a Nested stack
Show Reddit: Typeformation: Type Cloudformation templates with pleasure!
Amazon Elasticsearch Service with CloudFormation stuck on delete_in_progress

I’ll say what I said last time because I think it’s important enough to repeat: you have to label your arrows. You are severely limiting the value of your diagrams when the arrows aren’t labeled. If I were to translate your example diagram to prose, it would look like this:

  • Distribution is related to Server… somehow.
  • Server is related to PublicSubnet1… somehow.
  • PublicSubnet1 is related to VPC… somehow.

And so on. Sure, an experienced dev can probably guess at the relations, but if you’re serious about documenting a system, that shouldn’t be good enough.

Thank you for reporting this requirement once again. Currently, tooltips are put on edges to indicate the related property but this is only available on svg / interactive outputs.

Context:

My VPC is deployed into 1 stack and each microservice has then its own stack with arguments mapped to exports from the vpc stack.

The vpc stack exports its outputs with key names with format - ${StackName}-${OutputKey}

The microservice stack expects a parameter that represents the vpc stack name and then derives the output it needs based on the format above.


Question:

  1. Does your app only work with yaml files (non-deployed stacks), or does it also take into consideration deployed stacks?

I am very much interested in seeing the “actual” resources across my infrastructure so that differences between environments/tenants are therefore more obvious.

  1. Can the app take a list of deployed stacks and match then in a single diagram?

Id be interested in this response too - to take things further does it support outputs/imports - and to take is another step further does it support ssm parameters as references (e.g AWS::SSM::Parameter::Value)

Anyone else having an extremely cluttered output?

Every automatic diagram tool I’ve ever used always looks like my couch exploded

> Does your app only work with yaml files (non-deployed stacks), or does it also take into consideration deployed stacks?

Currently the tool only supports yaml/json input files.

> Can the app take a list of deployed stacks and match then in a single diagram?

Currently no but this could be a cool feature to add in the future. Don’t hesitate to create an issue and pull request. Contributions are welcome.

Currently, nothing is done with outputs/imports. AWS::SSM::Parameter::Value is not supported but any AWS::SSM::Parameter::Value<…:Id> is supported. Don’t hesitate to create an issue and pull request. Contributions are welcome.

I still love Cloudcraft. I can filter the diagram to look at just what I want. I say it all the time, but how I wish AWS had bought the company and included the tech in everyone’s account.

These are still unusable and it’s still faster to just diagram the architecture out yourself.

I keep coming back every few months hoping that the diagrams are able to magically render data flow or network flow and then getting all sad after realizing they don’t.

Deployment dependencies (DependsOn, Ref, GetAtt) have very limited utility: they’re only good for troubleshooting CloudFormation deployments, but that’s not at all what people need diagrams for.

Thank you for this point of view, perhaps or not shared by many devops.

I am not so sure that drawing diagrams manually is faster that generating them automatically. This must be measured experimentally.

Perhaps you need architecture diagrams instead of infrastructure diagrams. Architecture diagrams focus on high level business aspects (like data flow) where infrastructure diagrams show a lot of low level technical details. Both kinds of diagrams have its own utility, they just target different use cases: business view vs technical view.

One future feature of AWS CloudFormation Diagrams will be to provide architecture diagrams. But this needs investigations to understand clearly what architects would like to see in the generated diagrams, and what they don’t care about. For instance, an architecture diagram for the WordPress use case should show only 2 nodes: the WordPressInstance using the WordPressDB. The rest is just technical aspects such as network and security. What do you thing about this?

Don’t get me wrong, manual diagramming still has high overhead and I strongly prefer an automated tool to help bootstrap it.

In this particular case, I mean the utility of the autogenerated CloudFormation diagrams is limited because they focus largely on things that are solved by CloudFormation already. Specifically: deployment dependencies. This graph is mostly useful when CloudFormation fails, but 90% of the time, that is not an issue and no one needs to look at it because CloudFormation largely just works.

Even in infrastructure engineering, what we care most about is how the cloud components are related in the space between deployments. I want to know how packets are routed, what sg rules allow and don’t allow, which lambda functions call which APIs. Diagrams assist with troubleshooting, planning, and review by subject matter experts.

Finally, no infrastructure is self-contained the point is to integrate with other software and systems, and there doesn’t appear to be clean way to relate components that exist outside of a stack.

I think there is great potential in autogenerating diagrams from CloudFormation, but there needs to be a way to annotate the invisible relationships that matter the most and remove autogenerated noise that is not as relevant. And I fully realize this is a hard problem to solve. I’m just suggesting it is a worthwhile problem to solve.

I really like the fact that you generate draw.io exports, this helps ease the ramp to adding useful context and denoising diagrams manually.

Also, I’m very curious about the architecture diagramming feature you alluded to. Are you willing to accept contributions or do you have an issue where you discuss the design/festure?

Thank you for your feedback. Contributions are welcome, don’t hesitate to submit PR at https://github.com/philippemerle/AWS-CloudFormation-Diagrams/pulls or issues at https://github.com/philippemerle/AWS-CloudFormation-Diagrams/issues or discussions at https://github.com/philippemerle/AWS-CloudFormation-Diagrams/discussions.