X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=ci%2FDockerfile-smo-install;h=99872f6225dbddfd9991a27df05054e0a5b1517e;hb=623251a70da40b8e4829f00b138e963caad5d261;hp=58d8295852abfdf32d4a6c9a4849c8baf857900a;hpb=4f3b7d49afece4e7eb505d7abf3d0c3f6e928cdc;p=it%2Fdep.git diff --git a/ci/Dockerfile-smo-install b/ci/Dockerfile-smo-install index 58d82958..99872f62 100644 --- a/ci/Dockerfile-smo-install +++ b/ci/Dockerfile-smo-install @@ -16,11 +16,22 @@ # ############################################################################## FROM ubuntu:18.04 -RUN apt-get update && apt-get -y install curl ca-certificates wget +RUN apt-get update && apt-get -y install ca-certificates wget # often times out during LF jenkins build +ARG USERNAME=ubuntu +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 \ + && apt-get install -y sudo \ + && echo $USERNAME ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/$USERNAME \ + && chmod 0440 /etc/sudoers.d/$USERNAME + +USER $USERNAME ARG TGT=/tmp/it-dep -COPY . $TGT +COPY --chown=$USERNAME:$USERNAME . $TGT RUN ls -latr /tmp/it-dep # Remove the smo-install as this one will be verified in another verify job RUN $TGT/bin/verify-smo-install