Skip to content

Commit b999b38

Browse files
authored
CBST-04: add docker user group (#176)
1 parent a7a4d7d commit b999b38

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

docker/pbs.Dockerfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ RUN apt-get update && apt-get install -y \
2626
&& rm -rf /var/lib/apt/lists/*
2727

2828
COPY --from=builder /app/target/release/commit-boost-pbs /usr/local/bin
29+
30+
RUN groupadd -g 10001 commitboost && \
31+
useradd -u 10001 -g commitboost -s /sbin/nologin commitboost
32+
USER commitboost
33+
2934
ENTRYPOINT ["/usr/local/bin/commit-boost-pbs"]
3035

3136

docker/signer.Dockerfile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ RUN apt-get update && apt-get install -y \
2626
&& rm -rf /var/lib/apt/lists/*
2727

2828
COPY --from=builder /app/target/release/commit-boost-signer /usr/local/bin
29+
30+
RUN groupadd -g 10001 commitboost && \
31+
useradd -u 10001 -g commitboost -s /sbin/nologin commitboost
32+
USER commitboost
33+
2934
ENTRYPOINT ["/usr/local/bin/commit-boost-signer"]
3035

3136

0 commit comments

Comments
 (0)