Skip to content

Commit 82a5c83

Browse files
committed
Added creation of a group with the user's GID inside the docker container, if it's missing.
- Legacy-Id: 16098
1 parent 5707df2 commit 82a5c83

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

docker/docker-init.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,10 @@ if ! id -u "$USER" &> /dev/null; then
7676
useradd -s /bin/bash --groups staff,sudo --uid $UID --gid $GID $USER
7777
echo "$USER:$USER" | chpasswd
7878
fi
79+
if ! grep -q ":$GID:$" /etc/group ; then
80+
echo "Creating group entry for GID '$GID' ..."
81+
groupadd -g $GID users
82+
fi
7983

8084
VIRTDIR="/opt/home/$USER/$TAG"
8185
echo "Checking that there's a virtual environment for $TAG ..."

0 commit comments

Comments
 (0)