Change usermod to addgroup for docker access (#1641)

On Alpine Linux, the correct command to add a user to an existing group is addgroup <username> <groupname> rather than usermod -aG. The usermod command is part of the shadow package which is not installed by default on Alpine.
This commit is contained in:
Loïc Tosser
2026-01-15 01:45:23 +04:00
committed by GitHub
parent 0fc4a6daed
commit 8d9e9260e6

View File

@@ -540,7 +540,7 @@ if is_alpine; then
# Add the user to the docker group to allow access to the Docker socket if group docker exists
if getent group docker; then
echo "Adding beszel to docker group"
usermod -aG docker beszel
addgroup beszel docker
fi
elif is_openwrt; then