Update snapshot and/or references of policy/models to latest snapshots
[policy/models.git] / models-sim / policy-models-sim-pdp / src / main / package / docker / Dockerfile
index 93a3c9b..ee59a3e 100644 (file)
@@ -1,6 +1,7 @@
 #
 # ============LICENSE_START=======================================================
-#  Copyright (C) 2019 Nordix Foundation.
+#  Copyright (C) 2019-2021 Nordix Foundation.
+#  Modifications Copyright (C) 2019 AT&T Intellectual Property.
 # ================================================================================
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -22,7 +23,7 @@
 # Docker file to build an image that runs the PDP simulator on Java 8 in alpine
 #
 
-FROM onap/policy-common-alpine:1.4.0
+FROM onap/policy-jre-alpine:2.5.1-SNAPSHOT
 
 LABEL maintainer="Policy Team"
 
@@ -31,23 +32,6 @@ ARG POLICY_LOGS=/var/log/onap/policy/pdp-sim
 ENV POLICY_HOME=/opt/app/policy
 ENV POLICY_LOGS=${POLICY_LOGS}
 
-RUN apk add --no-cache --update \
-    bash \
-    nss \
-    procps \
-    coreutils \
-    findutils \
-    grep \
-    zip \
-    unzip \
-    curl \
-    wget \
-    openssh \
-    iproute2 \
-    iputils \
-    vim \
-    openjdk8
-
 # Create PDP simulator user and group
 # Add simulator-specific directories and set ownership as the simulator user
 RUN mkdir -p ${POLICY_HOME}/pdp-sim \
@@ -66,8 +50,8 @@ RUN tar xvfz /packages/policy-models-sim-pdp-tarball.tar.gz --directory ${POLICY
 COPY pdp-sim.sh ${POLICY_HOME}/pdp-sim/bin
 RUN find /opt/app -type d -perm 755 \
     && find /opt/app -type f -perm 644 \
-    && chmod a+x ${POLICY_HOME}/pdp-sim/bin/*
+    && chmod 755 ${POLICY_HOME}/pdp-sim/bin/*
 
 USER policy
 ENV PATH ${POLICY_HOME}/pdp-sim/bin:$PATH
-ENTRYPOINT [ "bash", "pdp-sim.sh" ]
+ENTRYPOINT [ "sh", "/opt/app/policy/pdp-sim/bin/pdp-sim.sh" ]