summaryrefslogtreecommitdiffstats
path: root/Dockerfile.dev
diff options
context:
space:
mode:
authorMauro Sardara <msardara@cisco.com>2022-07-08 16:10:13 +0000
committerMauro Sardara <msardara@cisco.com>2022-08-10 11:57:10 +0200
commit8f0a8bf572b9b8123121338a31462440bad65857 (patch)
treeecac67f0ad005b2eb0a1bd25c8f242497ffddea1 /Dockerfile.dev
parent8d27045832427a0ea345f48bfb2c42f46a357af1 (diff)
feat: add interest manifest serialization/deserialization
Also: add helpers for interest manifest Ref: HICN-738 Signed-off-by: Mauro Sardara <msardara@cisco.com> Change-Id: Ia531605148e00ccbe446da0f4f2d8caae2b098be Signed-off-by: Mauro Sardara <msardara@cisco.com>
Diffstat (limited to 'Dockerfile.dev')
-rw-r--r--Dockerfile.dev13
1 files changed, 13 insertions, 0 deletions
diff --git a/Dockerfile.dev b/Dockerfile.dev
index 43a0c4555..326f4676c 100644
--- a/Dockerfile.dev
+++ b/Dockerfile.dev
@@ -5,6 +5,10 @@ WORKDIR /hicn-build
COPY Makefile versions.cmake ./
COPY scripts scripts/
+ARG USERNAME=ubuntu
+ARG USER_UID=1000
+ARG USER_GID=${USER_UID}
+
RUN apt update && apt-get install -y \
make \
sudo \
@@ -14,4 +18,13 @@ RUN apt update && apt-get install -y \
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=