Update Dockerfile for PF base image 77/133277/1
authorliamfallon <liam.fallon@est.tech>
Tue, 14 Feb 2023 11:36:16 +0000 (11:36 +0000)
committerliamfallon <liam.fallon@est.tech>
Tue, 14 Feb 2023 11:36:19 +0000 (11:36 +0000)
The Policy Framework base image run under the "onap" user rather than
under the "root" user. This means that root access has to be enabled in
child Dockerfiles for configuraiton that requires root access.

Root access is turned off again later in the Dockerfile so that the
image will run under another user.

Issue-ID: POLICY-4558
Change-Id: I3cef40fa259f0646c75edcb835258d24e3fb0e9c
Signed-off-by: liamfallon <liam.fallon@est.tech>
packages/apex-pdp-docker/src/main/docker/Dockerfile

index 487fb06..c4bd4ad 100644 (file)
@@ -43,6 +43,7 @@ ENV POLICY_LOGS=$POLICY_LOGS
 ENV APEX_HOME=$POLICY_HOME
 ENV APEX_USER=policy
 
+USER root
 RUN mkdir -p $POLICY_HOME $POLICY_LOGS && \
     chown -R policy:policy $POLICY_HOME $POLICY_LOGS