diff options
author | jhh <jorge.hernandez-herrero@att.com> | 2020-02-16 19:49:42 -0600 |
---|---|---|
committer | jhh <jorge.hernandez-herrero@att.com> | 2020-02-17 11:49:35 -0600 |
commit | 927533c112b7bb50c7f19fe9a6286669ba572179 (patch) | |
tree | cffb513598a86be571e4326b475187abae917afd /controlloop/packages/docker-controlloop/src/main/docker | |
parent | bd3b962acb4ec6f8ae4c02c9364281295239fbd1 (diff) |
Inherit from PDP-D (native policies) base image
Depends on https://gerrit.onap.org/r/#/c/policy/docker/+/101758/
for package cleanup and the native Dockerfile refactoring from
https://gerrit.onap.org/r/#/c/policy/drools-pdp/+/101802/.
Issue-ID: POLICY-2181
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Change-Id: I6cf2b945157a91abd9985bcff1e70ae6a30ae15d
Signed-off-by: jhh <jorge.hernandez-herrero@att.com>
Diffstat (limited to 'controlloop/packages/docker-controlloop/src/main/docker')
-rw-r--r-- | controlloop/packages/docker-controlloop/src/main/docker/Dockerfile | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/controlloop/packages/docker-controlloop/src/main/docker/Dockerfile b/controlloop/packages/docker-controlloop/src/main/docker/Dockerfile index 98bf35a8e..464720360 100644 --- a/controlloop/packages/docker-controlloop/src/main/docker/Dockerfile +++ b/controlloop/packages/docker-controlloop/src/main/docker/Dockerfile @@ -3,23 +3,14 @@ FROM onap/policy-drools:@version.policy.drools-pdp@ ARG BUILD_VERSION_APP_CL=${BUILD_VERSION_APP_CL} ENV BUILD_VERSION_APP_CL=${BUILD_VERSION_APP_CL} -COPY /maven/apps-controlloop.zip $POLICY_INSTALL/ +COPY --chown=policy:policy /maven/apps-controlloop.zip $POLICY_INSTALL/ +COPY --chown=policy:policy /maven/pdpd-cl-entrypoint.sh $POLICY_HOME/bin/ RUN unzip apps-controlloop.zip && \ - mkdir -p $POLICY_HOME/logs $POLICY_HOME/config $HOME/.m2 && \ - tar -C $POLICY_HOME -xvf base-${BUILD_VERSION_DROOLS}.tar.gz --no-same-owner && \ tar -C $POLICY_HOME -xvf basex-controlloop-$BUILD_VERSION_APP_CL.tar.gz --no-same-owner && \ - unzip policy-management-${BUILD_VERSION_DROOLS}.zip -d $POLICY_HOME && \ - echo "source $POLICY_HOME/etc/profile.d/env.sh" >> "$HOME/.bashrc" && \ chmod 700 $POLICY_HOME/bin/* && \ chmod 600 $POLICY_HOME/config/* && \ - chmod 700 $POLICY_INSTALL/*.sh && \ - rm -f $POLICY_INSTALL/*.conf - -COPY /maven/docker-entrypoint.sh $POLICY_HOME/bin/ - -RUN . $POLICY_HOME/etc/profile.d/env.sh && \ - $POLICY_HOME/bin/features install healthcheck distributed-locking lifecycle && \ + . $POLICY_HOME/etc/profile.d/env.sh && \ $POLICY_HOME/bin/features install controlloop-utils controlloop-trans controlloop-management && \ $POLICY_HOME/bin/features install controlloop-amsterdam controlloop-usecases && \ $POLICY_HOME/bin/features enable healthcheck distributed-locking lifecycle && \ @@ -31,7 +22,7 @@ RUN . $POLICY_HOME/etc/profile.d/env.sh && \ -a $POLICY_HOME/features/controlloop-usecases/artifacts/controller-usecases-$BUILD_VERSION_APP_CL.jar && \ find $HOME/.m2/ -name _maven.repositories -exec rm -v {} \; && \ find $HOME/.m2/ -name _remote.repositories -exec rm -v {} \; && \ - rm $POLICY_INSTALL/*.zip $POLICY_INSTALL/*.gz 2> /dev/null + rm $POLICY_INSTALL/apps-controlloop.zip $POLICY_INSTALL/basex-controlloop-$BUILD_VERSION_APP_CL.tar.gz 2> /dev/null -ENTRYPOINT ["/opt/app/policy/bin/docker-entrypoint.sh"] +ENTRYPOINT ["/opt/app/policy/bin/pdpd-cl-entrypoint.sh"] CMD ["boot"] |