diff options
author | Timoney, Dan (dt5972) <dtimoney@att.com> | 2019-02-27 08:49:09 -0500 |
---|---|---|
committer | Timoney, Dan (dt5972) <dtimoney@att.com> | 2019-02-27 08:49:09 -0500 |
commit | 6570c8f2d8955d18be34831bbe25286e11a255af (patch) | |
tree | 6a36e00fd4f5032e578eb1b29fc57b9b332d5a6c | |
parent | c0c8de124db0d84992c796af836c8e73801b7366 (diff) |
Run ODL container as non-root user
Update sdnc ODL container to run as non-root user 'odl'
Change-Id: If23e061fe861eca9155874fe2462b20ca7219382
Issue-ID: SDNC-668
Signed-off-by: Timoney, Dan (dt5972) <dtimoney@att.com>
Former-commit-id: 6f2311e494d2fa1ff8635134bf5325a3ced4881e
-rwxr-xr-x | installation/sdnc/src/main/docker/Dockerfile | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/installation/sdnc/src/main/docker/Dockerfile b/installation/sdnc/src/main/docker/Dockerfile index 7f7c0dea..df392101 100755 --- a/installation/sdnc/src/main/docker/Dockerfile +++ b/installation/sdnc/src/main/docker/Dockerfile @@ -13,6 +13,8 @@ ENV JAVA_SECURITY_DIR $SSL_CERTS_DIR/java ENV SDNC_NORTHBOUND_REPO mvn:org.onap.sdnc.northbound/sdnc-northbound-all/${sdnc.northbound.version}/xml/features +USER root + # imstall ssl and java certificates COPY AAF_RootCA.cer $SSL_CERTS_DIR @@ -35,6 +37,8 @@ RUN cp $ODL_HOME/etc/org.apache.karaf.features.cfg $ODL_HOME/etc/org.apache.kara RUN sed -i -e "\|featuresRepositories|s|$|,${SDNC_NORTHBOUND_REPO}|" $ODL_HOME/etc/org.apache.karaf.features.cfg RUN sed -i -e "\|featuresBoot[^a-zA-Z]|s|$|,sdnc-northbound-all|" $ODL_HOME/etc/org.apache.karaf.features.cfg +RUN chown -R odl /opt +USER odl ENTRYPOINT /opt/onap/sdnc/bin/startODL.sh EXPOSE 8181 |