From 07df9aa035f85cff83604de41acad3178fc40e63 Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Sun, 24 Mar 2024 00:03:32 -0400 Subject: [PATCH] Ensure user is in a group --- orchestration/src/main.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/orchestration/src/main.rs b/orchestration/src/main.rs index 823e1b61..13b98554 100644 --- a/orchestration/src/main.rs +++ b/orchestration/src/main.rs @@ -96,8 +96,8 @@ ENV LD_PRELOAD=libmimalloc.so RUN apk update && apk upgrade -# System user (not a human), shell of nologin, no password assigned -RUN adduser -S -s /sbin/nologin -D {user} +RUN adduser --system --shell /sbin/nologin --disabled-password {user} +RUN addgroup {user} {user} # Make the /volume directory and transfer it to the user RUN mkdir /volume && chown {user}:{user} /volume @@ -120,7 +120,7 @@ RUN echo "/usr/lib/libmimalloc.so" >> /etc/ld.so.preload RUN apt update && apt upgrade -y && apt autoremove -y && apt clean -RUN useradd --system --create-home --shell /sbin/nologin {user} +RUN useradd --system --user-group --create-home --shell /sbin/nologin {user} # Make the /volume directory and transfer it to the user RUN mkdir /volume && chown {user}:{user} /volume