diff options
author | Pawel Wieczorek <p.wieczorek2@samsung.com> | 2020-03-30 11:43:19 +0200 |
---|---|---|
committer | Sunder Tattavarada <statta@research.att.com> | 2020-04-03 16:48:44 +0000 |
commit | 25a604f80ce90270ff7d104caff2fdd6948cbfa1 (patch) | |
tree | cd24ed66ccd1ff7cf5f1c6c605e449848abb6c45 /deliveries | |
parent | ae737cbbbe7c602e46a6093db9ae924900e603e5 (diff) |
Migrate Dockerfile.portal to unprivileged user
Issue-ID: PORTAL-849
Change-Id: I3060de8beddcba03be45f19ce8cd1fd0e32e62f5
Signed-off-by: Pawel Wieczorek <p.wieczorek2@samsung.com>
(cherry picked from commit 048ca4538f32b27667271d1a32f5a95b0731f1f9)
Diffstat (limited to 'deliveries')
-rw-r--r-- | deliveries/Dockerfile.portal | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/deliveries/Dockerfile.portal b/deliveries/Dockerfile.portal index f12a3e30..cce3ed09 100644 --- a/deliveries/Dockerfile.portal +++ b/deliveries/Dockerfile.portal @@ -41,6 +41,10 @@ COPY ${FE_DIR} ${PORTALCONTEXT}/public VOLUME ${TOMCATHOME}/logs +# Switch to unprivileged user +RUN addgroup -g 1000 -S portal && adduser -u 1000 -S portal -G portal +USER portal + # Switch back to root WORKDIR / |