mirror of
https://github.com/ArchiveBox/ArchiveBox
synced 2024-11-10 06:34:16 +00:00
fix shell re-quoting in docker_entrypoint.sh so that quoted subcommands can be passed in
This commit is contained in:
parent
83eede54da
commit
48c9a49d56
1 changed files with 2 additions and 2 deletions
|
@ -107,12 +107,12 @@ if [[ "$1" == /* || "$1" == "bash" || "$1" == "sh" || "$1" == "echo" || "$1" ==
|
||||||
# "docker run archivebox /venv/bin/ipython3"
|
# "docker run archivebox /venv/bin/ipython3"
|
||||||
# "docker run archivebox /bin/bash -c '...'"
|
# "docker run archivebox /bin/bash -c '...'"
|
||||||
# "docker run archivebox cat /VERSION.txt"
|
# "docker run archivebox cat /VERSION.txt"
|
||||||
exec gosu "$PUID" bash -c "$*"
|
exec gosu "$PUID" bash -c "$(printf ' %q' "$@")"
|
||||||
else
|
else
|
||||||
# handle "docker run archivebox add some subcommand --with=args abc" by calling archivebox to run as args as CLI subcommand
|
# handle "docker run archivebox add some subcommand --with=args abc" by calling archivebox to run as args as CLI subcommand
|
||||||
# e.g. "docker run archivebox help"
|
# e.g. "docker run archivebox help"
|
||||||
# "docker run archivebox add --depth=1 https://example.com"
|
# "docker run archivebox add --depth=1 https://example.com"
|
||||||
# "docker run archivebox manage createsupseruser"
|
# "docker run archivebox manage createsupseruser"
|
||||||
# "docker run archivebox server 0.0.0.0:8000"
|
# "docker run archivebox server 0.0.0.0:8000"
|
||||||
exec gosu "$PUID" bash -c "archivebox $*"
|
exec gosu "$PUID" bash -c "archivebox $(printf ' %q' "$@")"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue