diff options
Diffstat (limited to 'Dockerfile')
-rw-r--r--[l---------] | Dockerfile | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/Dockerfile b/Dockerfile index 91fb519b8..ad7f99785 120000..100644 --- a/Dockerfile +++ b/Dockerfile @@ -1 +1,33 @@ -Dockerfile.dev
\ No newline at end of file +FROM ubuntu:focal +ENV DEBIAN_FRONTEND=noninteractive +WORKDIR /hicn-build + +ARG USERNAME=ubuntu +ARG USER_UID=1000 +ARG USER_GID=${USER_UID} + +COPY Makefile versions.cmake ./ +COPY scripts scripts/ + +USER root + +RUN apt update && apt-get install -y \ + make \ + sudo \ + curl \ + valgrind \ + git \ + zsh + +RUN make deps debug-tools + +# Add non-root user +RUN groupadd --gid ${USER_GID} ${USERNAME} && \ + useradd -s /bin/bash --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} +WORKDIR /home/${USERNAME} + +ENV DEBIAN_FRONTEND= |