From 82a5c83a5dbbcab41462f4fbe9ffec0045a6dfcd Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Sun, 24 Mar 2019 15:27:15 +0000 Subject: [PATCH] Added creation of a group with the user's GID inside the docker container, if it's missing. - Legacy-Id: 16098 --- docker/docker-init.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docker/docker-init.sh b/docker/docker-init.sh index a80f34131..4cda79698 100644 --- a/docker/docker-init.sh +++ b/docker/docker-init.sh @@ -76,6 +76,10 @@ if ! id -u "$USER" &> /dev/null; then useradd -s /bin/bash --groups staff,sudo --uid $UID --gid $GID $USER echo "$USER:$USER" | chpasswd fi +if ! grep -q ":$GID:$" /etc/group ; then + echo "Creating group entry for GID '$GID' ..." + groupadd -g $GID users +fi VIRTDIR="/opt/home/$USER/$TAG" echo "Checking that there's a virtual environment for $TAG ..."