Skip to content

Commit

Permalink
Merge pull request #23630 from Gchbg/dockerscript
Browse files Browse the repository at this point in the history
Fix podman-docker.sh under -eu shells
  • Loading branch information
openshift-merge-bot[bot] authored Aug 15, 2024
2 parents 85780ce + 004c040 commit 48c8994
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docker/podman-docker.sh
Original file line number Diff line number Diff line change
@@ -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
Expand Down

0 comments on commit 48c8994

Please sign in to comment.