mirror of
https://github.com/linuxserver/docker-d2-builder.git
synced 2026-02-20 04:14:08 +08:00
Support raw runs with no svg generation
This commit is contained in:
parent
e4c1ee975b
commit
492c82d3f6
@ -22,7 +22,7 @@ docker pull lscr.io/linuxserver/d2-builder:latest && \
|
||||
docker run -d --rm -v /tmp/d2:/output -v /opt/repos:/input:ro -e PUID=1000 -e PGID=1000 -e LOCAL=true lscr.io/linuxserver/d2-builder:latest mastodon:latest
|
||||
```
|
||||
|
||||
Generated svg files will be created in `/output`.
|
||||
Generated d2 and svg files will be created in `/output`. If `RAW=true` then only d2 files will be created.
|
||||
|
||||
## Versions
|
||||
|
||||
|
||||
@ -94,13 +94,13 @@ done
|
||||
shopt -s globstar
|
||||
|
||||
cat <<EOF > "/output/${OUTPUTNAME}"
|
||||
vars: {
|
||||
d2-config: {
|
||||
layout-engine: elk
|
||||
theme-id: 1
|
||||
dark-theme-id: 200
|
||||
}
|
||||
vars: {
|
||||
d2-config: {
|
||||
layout-engine: elk
|
||||
theme-id: 1
|
||||
dark-theme-id: 200
|
||||
}
|
||||
}
|
||||
|
||||
EOF
|
||||
|
||||
|
||||
@ -9,6 +9,9 @@ else
|
||||
TAGNAME="latest"
|
||||
fi
|
||||
|
||||
s6-setuidgid abc d2 "/output/${IMAGENAME}-${TAGNAME}.d2" "/output/${IMAGENAME}-${TAGNAME}.svg"
|
||||
|
||||
chmod 644 "/output/${IMAGENAME}-${TAGNAME}.d2" "/output/${IMAGENAME}-${TAGNAME}.svg"
|
||||
if [[ -z ${RAW} ]]; then
|
||||
s6-setuidgid abc d2 "/output/${IMAGENAME}-${TAGNAME}.d2" "/output/${IMAGENAME}-${TAGNAME}.svg"
|
||||
chmod 644 "/output/${IMAGENAME}-${TAGNAME}.d2" "/output/${IMAGENAME}-${TAGNAME}.svg"
|
||||
else
|
||||
chmod 644 "/output/${IMAGENAME}-${TAGNAME}.d2"
|
||||
fi
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user