mirror of
https://github.com/microsoft/mscclpp.git
synced 2026-05-12 09:17:06 +00:00
14 lines
354 B
Docker
14 lines
354 B
Docker
ARG BASE_IMAGE
|
|
FROM ${BASE_IMAGE}
|
|
ARG USERNAME=mscclpp
|
|
ARG USER_UID=1000
|
|
ARG USER_GID=$USER_UID
|
|
|
|
# Create the user
|
|
RUN groupadd --gid $USER_GID $USERNAME && \
|
|
useradd --uid $USER_UID --gid $USER_GID -m $USERNAME && \
|
|
echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME && \
|
|
chmod 0440 /etc/sudoers.d/$USERNAME
|
|
|
|
USER $USERNAME
|