Diagrams

"图表即代码"用于云系统架构的原型设计。「🎨 Diagram as Code for prototyping cloud system architectures」

Github stars Tracking Chart

Diagrams

图表即代码

Diagrams 让你用 Python 代码绘制云系统架构。它的诞生是为了在没有任何设计工具的情况下对一个新的系统架构设计进行原型设计。你也可以描述或可视化现有的系统架构。Diagrams 目前支持主要的供应商,包括:AWS, Azure, GCP, Kubernetes, Alibaba Cloud, Oracle Cloud 等。它还支持内部节点、SaaS 和主要的编程框架和语言。

Diagram as Code 还允许你在任何版本控制系统中跟踪架构图的变化。

注意:它不控制任何实际的云资源,也不产生云的形成或地貌代码。它只是用于绘制云系统架构图。

Providers

aws provider azure provider gcp provider ibm provider kubernetes provider alibaba cloud provider oracle cloud provider openstack provider firebase provider digital ocean provider elastic provider outscale provider on premise provider generic provider programming provider saas provider c4 provider

开始使用

它需要Python 3.7或更高版本,请先检查你的Python版本。

它使用 Graphviz 来渲染图,所以你需要安装 Graphviz 来使用图。安装 Graphviz 后(或者已经有了),安装 diagrams。

macOS 用户如果使用 Homebrew,可以通过 brew install graphviz 下载 Graphviz。

# using pip (pip3)
$ pip install diagrams

# using pipenv
$ pipenv install diagrams

# using poetry
$ poetry add diagrams

您可以从快速启动开始。查看指南了解更多详情,您还可以在这里找到所有可用节点列表。

Examples

Event Processing Stateful Architecture Advanced Web Service
event processing stateful architecture advanced web service with on-premise

您可以在 examples 页面找到所有示例。

贡献

要对 diagram 做出贡献,请查看贡献指南

如果你正在使用 diagram,请告诉我。我会把你添加到展示页面中。(我正在努力!) :)

谁在使用它?

Apache Airflow 是最流行的数据工作流协调器。Airflow 在其文档中使用 Diagrams 生成架构图。

Cloudiscovery 可帮助您分析云(AWS/GCP/Azure/Alibaba/IBM)账户中的资源。它允许您基于该图表库创建云资源地图分析图表,因此您可以使用 Cloudiscovery 绘制现有的云基础设施。

Airflow Diagrams 是一个 Airflow 插件,旨在通过图表轻松地将你的 Airflow DAGs 在 AWS、GCP、Azure 等供应商的服务层面可视化。

GitPitch 是技术会议、培训、开发人员倡导者和教育工作者的完美幻灯片解决方案。图解现在可以作为一个专门的云图标记小工具使用,因此你可以在会议、聚会和培训的任何幻灯片上直接使用图解。

其他语言

如果你熟悉 Go,你也可以使用 go-diagrams

许可证

MIT

 

 

Overview

Name With Ownermingrammer/diagrams
Primary LanguagePython
Program languageShell (Language Count: 5)
PlatformLinux, Mac, Windows
License:MIT License
Release Count41
Last Release Namev0.23.4 (Posted on )
First Release Namev0.2.0 (Posted on )
Created At2020-02-02 15:23:24
Pushed At2024-04-16 12:57:09
Last Commit At2024-04-13 14:05:08
Stargazers Count34.8k
Watchers Count389
Fork Count2.2k
Commits Count534
Has Issues Enabled
Issues Count484
Issue Open Count295
Pull Requests Count255
Pull Requests Open Count81
Pull Requests Close Count144
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private

diagrams logo

Diagrams

license
pypi version
python version
Run tests
todos
contributors

Diagram as Code.

Diagrams lets you draw the cloud system architecture in Python code. It was born for prototyping a new system architecture design without any design tools. You can also describe or visualize the existing system architecture as well. Diagrams currently supports main major providers including: AWS, Azure, GCP, Kubernetes, Alibaba Cloud, Oracle Cloud etc... It also supports On-Premise nodes, SaaS and major Programming frameworks and languages.

Diagram as Code also allows you to track the architecture diagram changes in any version control system.

NOTE: It does not control any actual cloud resources nor does it generate cloud formation or terraform code. It is just for drawing the cloud system architecture diagrams.

Providers

aws provider
azure provider
gcp provider
ibm provider
kubernetes provider
alibaba cloud provider
oracle cloud provider
openstack provider
firebase provider
digital ocean provider
elastic provider
outscale provider
on premise provider
generic provider
programming provider
saas provider
c4 provider

Getting Started

It requires Python 3.7 or higher, check your Python version first.

It uses Graphviz to render the diagram, so you need to install Graphviz to use diagrams. After installing graphviz (or already have it), install the diagrams.

macOS users can download the Graphviz via brew install graphviz if you're using Homebrew.

# using pip (pip3)
$ pip install diagrams

# using pipenv
$ pipenv install diagrams

# using poetry
$ poetry add diagrams

You can start with quick start. Check out guides for more details, and you can find all available nodes list in here.

Examples

Event Processing Stateful Architecture Advanced Web Service
event processing stateful architecture advanced web service with on-premise

You can find all the examples on the examples page.

Contributing

To contribute to diagram, check out contribution guidelines.

Let me know if you are using diagrams! I'll add you in showcase page. (I'm working on it!) :)

Who uses it?

Apache Airflow is the most popular data workflow Orchestrator. Airflow uses Diagrams to generate architecture diagrams in their documentation.

Cloudiscovery helps you to analyze resources in your cloud (AWS/GCP/Azure/Alibaba/IBM) account. It allows you to create a diagram of analyzed cloud resource map based on this Diagrams library, so you can draw your existing cloud infrastructure with Cloudiscovery.

Airflow Diagrams is an Airflow plugin that aims to easily visualise your Airflow DAGs on service level from providers like AWS, GCP, Azure, etc. via diagrams.

Other languages

  • If you are familiar with Go, you can use go-diagrams as well.

License

MIT

To the top