Skip to content
Snippets Groups Projects
Verified Commit a11c40ef authored by David Beniamine's avatar David Beniamine
Browse files

Readme up

parent 3afa34a9
Branches
No related tags found
No related merge requests found
Pipeline #500 canceled
...@@ -6,15 +6,20 @@ Base on [docker-compose-viz-mermaid](https://github.com/derlin/docker-compose-vi ...@@ -6,15 +6,20 @@ Base on [docker-compose-viz-mermaid](https://github.com/derlin/docker-compose-vi
``` ```
# Directly generate an image of with 1000px
docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -M -otest.png -M -w1000 docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -M -otest.png -M -w1000
# Generate a svg with default parameters for mermaid and showing the ports
docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -v -p -m docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -v -p -m
# Generates the markdown sources with a mermaid block showing ports
docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -v -p -v -fMARKDOWN docker run --rm -it -v $PWD:/data dbeniamine/docker-compose-viz-mermaid -v -p -v -fMARKDOWN
``` ```
## snippet ## Configuration
Add the following to your `.bashrc` suits, to your needs I recommand to use the `dcviz` command to call `docker-compose-viz-mermaid`, it parses a complex `docker-compose` configuration with `docker-compose config` before calling the visualization tool :
To add the `dcviz` command, add the following code to your `.bashrc`, note that you can change the default arguments to suit your needs
```bash ```bash
dcviz() { dcviz() {
...@@ -23,3 +28,5 @@ dcviz() { ...@@ -23,3 +28,5 @@ dcviz() {
rm $$.yml > /dev/null 2>&1 rm $$.yml > /dev/null 2>&1
} }
``` ```
Then you can simply run `dcviz -M -omyimage.png` to generate the image or `dcviz -v -fMARKDOWN` to get the markdown sources
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment