Git Product home page Git Product logo

ndiag's Introduction

ndiag

ndiag is a "high-level architecture" diagramming/documentation tool.

Key features of ndiag are:

  • N-diagrams: Generate multiple "diagrams and documents" (views) from a single configuration.
  • Nested-clusters: Nodes and components can be clustered in nested layers
  • Provides the ability to check the difference between the architecture and the actual system.

Usage

$ ndiag doc -c ndiag.yml --rm-dist

Getting Started

Generate architecture documents

Add ndiag.yml (Full version is here).

---
name: 3-Tier Architecture
docPath: docs/arch
views:
  -
    name: overview
    layers: ["consul", "vip_group"]
  -
    name: http-lb
    layers: ["vip_group"]
    labels: ["http"]
nodes:
  -
    name: lb
    match: lb-*
    components:
      - NGINX?icon=lb-l7
    clusters:
      - 'Consul:dc1'
      - 'vip_group:lb'
  -
    name: app
    match: app-*
    components:
      - NGINX?icon=proxy
      - Rails App?icon=cube4&label=lang:ruby
    clusters:
      - 'Consul:dc1'
  -
    name: db
    match: db-*
    components:
      - PostgreSQL?icon=db
    clusters:
[...]

Run ndiag doc to generate documents in GitHub Friendly Markdown format.

$ ndiag doc -c ndiag.yml

Commit ndiag.yml and documents.

$ git add ndiag.yml doc/arch ndiag.description
$ git commit -m 'Add architecture document'
$ git push origin main

View the document on GitHub.

Example document

example

Tutorial

Install

deb:

$ export NDIAG_VERSION=X.X.X
$ curl -o ndiag.deb -L https://github.com/k1LoW/ndiag/releases/download/v$NDIAG_VERSION/ndiag_$NDIAG_VERSION-1_amd64.deb
$ dpkg -i ndiag.deb

RPM:

$ export NDIAG_VERSION=X.X.X
$ yum install https://github.com/k1LoW/ndiag/releases/download/v$NDIAG_VERSION/ndiag_$NDIAG_VERSION-1_amd64.rpm

apk:

$ export NDIAG_VERSION=X.X.X
$ curl -o ndiag.apk -L https://github.com/k1LoW/ndiag/releases/download/v$NDIAG_VERSION/ndiag_$NDIAG_VERSION-1_amd64.apk
$ apk add ndiag.apk

homebrew tap:

$ brew install k1LoW/tap/ndiag

aqua:

$ aqua g -i k1LoW/ndiag

manually:

Download binary from releases page

go install:

$ go install github.com/k1LoW/ndiag@latest

docker:

$ docker pull ghcr.io/k1low/ndiag:latest

temporary:

$ source <(curl https://git.io/ndiag)
$ curl -sL https://git.io/ndiag > /tmp/ndiag.tmp && . /tmp/ndiag.tmp

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.