summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--packages/docker/src/main/docker/Dockerfile36
1 files changed, 12 insertions, 24 deletions
diff --git a/packages/docker/src/main/docker/Dockerfile b/packages/docker/src/main/docker/Dockerfile
index c6397b62..6f4d9a28 100644
--- a/packages/docker/src/main/docker/Dockerfile
+++ b/packages/docker/src/main/docker/Dockerfile
@@ -1,41 +1,29 @@
-FROM alpine:3.9
+FROM onap/policy-common-alpine:1.4.0
+
+LABEL maintainer="Policy Team"
-ARG BUILD_VERSION=${BUILD_VERSION}
-ARG POLICY_HOME=/opt/app/policy
ARG POLICY_LOGS=/var/log/onap/policy/pdpd
ARG POLICY_INSTALL=/tmp/policy-install
-ENV BUILD_VERSION ${BUILD_VERSION}
-ENV JAVA_HOME /usr/lib/jvm/java-1.8-openjdk
-
ENV POLICY_INSTALL ${POLICY_INSTALL}
ENV POLICY_INSTALL_INIT ${POLICY_INSTALL}/config
-ENV POLICY_HOME ${POLICY_HOME}
ENV POLICY_LOGS ${POLICY_LOGS}
ENV POLICY_CONFIG ${POLICY_HOME}/config
ENV POLICY_LOGBACK ${POLICY_CONFIG}/logback.xml
ENV POLICY_DOCKER true
-RUN apk update && \
- apk add --update --no-cache busybox-extras \
- bash bash-completion procps \
- coreutils less grep findutils \
- zip unzip file \
- nss openssl openssh \
- python py-pip openjdk8 maven \
- curl wget httpie jq
-
-RUN addgroup -S policy && adduser -S policy -s /bin/bash
+RUN apk add --no-cache \
+ mariadb-client \
+ file \
+ bash-completion \
+ openssl \
+ less \
+ && pip install http-prompt
-# install MariaDB client
-RUN apk add --update --no-cache mariadb-client && rm -rf /var/cache/apk/*
-
-RUN pip install http-prompt
-RUN mkdir -p ${POLICY_HOME}/config ${POLICY_LOGS} ${POLICY_INSTALL_INIT} && \
- chown -R policy:policy ${POLICY_HOME} ${POLICY_LOGS} ${POLICY_INSTALL}
+RUN mkdir -p ${POLICY_CONFIG} ${POLICY_LOGS} ${POLICY_INSTALL_INIT} && \
+ chown -R policy:policy ${POLICY_LOGS} ${POLICY_INSTALL}
WORKDIR ${POLICY_INSTALL}
-
COPY install-drools.zip docker-install.sh do-start.sh wait-for-port.sh ./
VOLUME [ "${POLICY_INSTALL_INIT}" ]