Comments (7)
@MindaugasLaganeckas i could replicate the issue on ubuntu, docker uses the host file permissions when using bind mounts so the (host) data
directory doesn't provide write access to the docker (mermaidcli) user.
i see two possible solutions to this (without modifying the dockerfile),
- pass
-u $UID
at runtime. (as suggested by @fconil ) - modify the permissions for the
data
directory to777
that way user groups outside of the host user can have write access to it (but this is a security risk).
from mermaid-cli.
I will update the Known issues
in README and close this issue. Please, reopen if you disagree.
from mermaid-cli.
It works if the user is switched to root podman run -it -v "$(pwd)":/data:z -u root minlag/mermaid-cli -i /data/diagram.mmd
.
from mermaid-cli.
I have switched from root to mermaidcli in docker images. But I did not see any problem when running the tests:
Line 8 in 194060f
Can you try to map data to /home/mermaidcli/data instead and see if that works without specifying root in the cli?
from mermaid-cli.
Thanks for the reply. I get the same issues. What OS are you using?
from mermaid-cli.
I am using ubuntu in my tests:
from mermaid-cli.
Had the same issue with docker on Ubuntu, solved using docker -u option with my uid
docker run -u <user_uid> -it --rm -v "$(pwd)":data minlag/mermaid-cli -i /data/diagram.mmd
from mermaid-cli.
Related Issues (20)
- Apply styles from inside mermaid graphs
- Bug: CSS Styling Not Applied to SVG (only PNG / static image)
- Add types for exports
- How can I configure maxEdges using the CLI? (Error: Too many edges) HOT 1
- Error: net::ERR_ACCESS_DENIED on /@mermaid-js/mermaid-cli/dist/index.html HOT 3
- Error: Could not find Chromium (rev. 1108766) HOT 7
- Syntax Error in Mermaid-cli tool HOT 1
- background of edge label is white in pdf from flowchart
- Missing description in `-h, --help`
- Custom image output for .md file input HOT 1
- SyntaxError: The requested module `@mermaid-js/mermaid-cli` does not provide an export named 'run' (via SyntaxError) HOT 1
- Formatting of diagram is changed when exported to svg, pdf or png
- Could not find Chromium (rev. 1108766) HOT 9
- Upgrade mermaid to 10.9.0 (Latex support) HOT 2
- Write output to stdout HOT 1
- Document mermaid-cli release procedure
- mmdc not generating labels for SVG outputs HOT 2
- improve performance of markdown file processing HOT 2
- Version bump happens after tagging HOT 3
- Trying to use browserUrl or browserWSEndpoint without success HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mermaid-cli.