mirror of https://github.com/containers/podman.git
Merge pull request #23630 from Gchbg/dockerscript
Fix podman-docker.sh under -eu shells
This commit is contained in:
commit
48c8994984
|
|
@ -1,10 +1,10 @@
|
|||
# DOCKER_HOST initialization
|
||||
|
||||
if [ -z "$DOCKER_HOST" ]; then
|
||||
if [ -z "${DOCKER_HOST-}" ]; then
|
||||
if [ $(id -u) -eq 0 ]; then
|
||||
export DOCKER_HOST=unix:///run/podman/podman.sock
|
||||
else
|
||||
if [ -n "$XDG_RUNTIME_DIR" ]; then
|
||||
if [ -n "${XDG_RUNTIME_DIR-}" ]; then
|
||||
export DOCKER_HOST=unix://$XDG_RUNTIME_DIR/podman/podman.sock
|
||||
fi
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in New Issue