Diagram as Code

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Scout Monitoring - Free Django app performance insights with Scout Monitoring
Get Scout setup in minutes, and let us sweat the small stuff. A couple lines in settings.py is all you need to start monitoring your apps. Sign up for our free tier today.
InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
  • diagrams

    :art: Diagram as Code for prototyping cloud system architectures

    Python has dunder methods that allow you to override behaviour (eg operator overloading, hashing, object identity etc).

    In this case they’re overriding bitshifting.


  • Scout Monitoring

    Free Django app performance insights with Scout Monitoring. Get Scout setup in minutes, and let us sweat the small stuff. A couple lines in settings.py is all you need to start monitoring your apps. Sign up for our free tier today.

    Scout Monitoring logo
  • inframap

    Read your tfstate or HCL to generate a graph specific for each provider, showing only the resources that are most important/relevant.

    Pretty cool. The biggest thing I think is missing from many popular diagramming tools is the ability to easily diff the architecture across changes. Although that can already be done with graphviz source files.

    However, these days I prefer to just have diagrams generated from the source code itself, like:

    - https://github.com/cycloidio/inframap

    - https://graphviz.org/Gallery/directed/bazel.html

    In order to make a compelling use case out of having to maintain a parallel definition like this, I think it needs to be able to contribute to analysis like formal verification or, despite them stating that it's not a goal, being able to create the described architecture. Or even generate something like a terraform plan. Otherwise it falls victim to the same problem as any other method of creating diagrams, that of them falling out of sync with the system.

    They are a long way there already by providing a way to use a programming language backed by a large ecosystem of other tools that can be used to work with e.g. terraform, like python/go.

  • plumbum

    Plumbum: Shell Combinators

    if you liked that, you'll love Plumbum[1] :)

    [1] https://github.com/tomerfiliba/plumbum

  • java

    Structurizr for Java (by structurizr)

    I love the idea of autogenerating diagrams from either a schema or from some sort of actual definitions (terraform/cloud inspection/etc), but I've generally found that the layout can be pretty poor for any semi-complex system.

    Even worse, a small change to the structure will typically cause a full re-layout, and place nodes completely differently to the previous output, making visual/mental comparisons between versions quite taxing.

    Given that autolayout is likely never going to be as good as someone doing some amount of manual layout or at least hinting, it'd be nice if there was some way to allow explicit placement of items and track it as metadata independently of the model changes.

    I think Structurizr[1] has some capabilities along these lines, but the editor wasn't great the last time I tried it, and I think largely requires their SaaS for tracking that layout info.

    Another option might be to feed it all into some flavour of graph DB with interactive querying/filtering and layout, and let users produce just the diffs / bits that they care about, if practical.

    [1] https://structurizr.com/

  • c4-notation

    Technical resources for using the C4 model for visualizing software architecture.

  • modules.tf-lambda

    Infrastructure as code generator - from visual diagrams created with Cloudcraft.co to Terraform

    I tried doing an AWS systems architecture and it looked so ugly, so, we switcehd to Cloudcraft [0], which does both isometric 3D and 2D. All Terraform tools like inframap were terrible, too. It's 2022 and we still don't have pretty autodiagraming tools - we have ML generating unimaginable in terms of complexity photorealistic images, but it can't generate a pretty diagram yet!

    [0]: https://www.cloudcraft.co/

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Interactive Architecture Diagrams

    4 projects | /r/devops | 15 Nov 2021
  • How to install and use inframap?

    1 project | /r/Terraform | 17 Mar 2022
  • Using Terraform with Lucid Chart

    2 projects | /r/Terraform | 9 Aug 2021
  • Create Architecture Diagram as Code for a 2-Tier Bookstore Application

    2 projects | dev.to | 9 Jul 2024
  • tenv alternatives - tfenv and terraform-switcher

    3 projects | 29 Jun 2024