Skip to content

Commit

Permalink
Module Docker: Check if SUDO_USER variable is defined
Browse files Browse the repository at this point in the history
  • Loading branch information
igorpecovnik committed Jan 10, 2025
1 parent 0140bc4 commit 343887d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/modules/software/module_docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function module_docker() {
fi

groupadd docker 2>/dev/null || true
usermod -aG docker $SUDO_USER
[[ -n "${SUDO_USER}" ]] && usermod -aG docker "${SUDO_USER}"
systemctl enable docker.service > /dev/null 2>&1
systemctl enable containerd.service > /dev/null 2>&1
systemctl start docker.service > /dev/null 2>&1
Expand Down

0 comments on commit 343887d

Please sign in to comment.