mirror of
https://github.com/docker/docker-install.git
synced 2026-11-20 10:03:11 +03:00
Merge pull request #178 from AkihiroSuda/rootless-safe-fallback
rootless-install.sh: use safer XRD on non-systemd hosts
This commit is contained in:
1 file changed
+3
-2
+3
-2
@@ -101,8 +101,8 @@ checks() {
|
||||
>&2 echo "- or simply log back in as the desired unprivileged user (ssh works for remote machines)"
|
||||
exit 1
|
||||
fi
|
||||
export XDG_RUNTIME_DIR="/tmp/docker-$(id -u)"
|
||||
mkdir -p "$XDG_RUNTIME_DIR"
|
||||
export XDG_RUNTIME_DIR="$HOME/.docker/run"
|
||||
mkdir -p -m 700 "$XDG_RUNTIME_DIR"
|
||||
XDG_RUNTIME_DIR_CREATED=1
|
||||
fi
|
||||
|
||||
@@ -307,6 +307,7 @@ print_instructions() {
|
||||
echo "# Make sure the following environment variables are set (or add them to ~/.bashrc):\n"
|
||||
|
||||
if [ -n "$XDG_RUNTIME_DIR_CREATED" ]; then
|
||||
echo "# WARN: systemd not found. You have to remove XDG_RUNTIME_DIR manually on every logout."
|
||||
echo "export XDG_RUNTIME_DIR=$XDG_RUNTIME_DIR"
|
||||
fi
|
||||
|
||||
|
||||
Reference in new issue
Block a user