mirror of
https://github.com/bitwarden/browser
synced 2025-12-10 21:33:27 +00:00
add shadow package, restore entrypoint functionality (#16124)
This commit is contained in:
@@ -67,6 +67,7 @@ EXPOSE 5000
|
||||
|
||||
RUN apk add --no-cache curl \
|
||||
icu-libs \
|
||||
shadow \
|
||||
&& apk add --no-cache --repository=http://dl-cdn.alpinelinux.org/alpine/edge/community gosu
|
||||
|
||||
# Copy app from the build stage
|
||||
|
||||
@@ -22,10 +22,11 @@ fi
|
||||
if [ "$(id -u)" = "0" ]; then
|
||||
# Create user and group
|
||||
|
||||
addgroup -g "$LGID" -S "$GROUPNAME" 2>/dev/null || true
|
||||
adduser -u "$LUID" -G "$GROUPNAME" -S -D -H "$USERNAME" 2>/dev/null || true
|
||||
mkdir -p /home/$USERNAME
|
||||
chown $USERNAME:$GROUPNAME /home/$USERNAME
|
||||
groupadd -o -g $LGID $GROUPNAME >/dev/null 2>&1 ||
|
||||
groupmod -o -g $LGID $GROUPNAME >/dev/null 2>&1
|
||||
useradd -o -u $LUID -g $GROUPNAME -s /bin/false $USERNAME >/dev/null 2>&1 ||
|
||||
usermod -o -u $LUID -g $GROUPNAME -s /bin/false $USERNAME >/dev/null 2>&1
|
||||
mkhomedir_helper $USERNAME
|
||||
|
||||
# The rest...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user