aboutsummaryrefslogtreecommitdiffstats
path: root/packages/docker/src/main/docker/Dockerfile
blob: d59e9d70e1874f131cf3a4ac9aa6118ea499d777 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM onap/policy-jdk-debian

LABEL maintainer="Policy Team"

ARG BUILD_VERSION_ENGINE=${BUILD_VERSION_ENGINE}
ARG POLICY_LOGS=/var/log/onap

ENV BUILD_VERSION_ENGINE ${BUILD_VERSION_ENGINE}
ENV POLICY_LOGS ${POLICY_LOGS}

RUN apt update && \
    apt-get install -y mariadb-client && \
    apt-get install -y netcat && \
    apt-get install -y cron && \
    mkdir -p /tmp/policy-install ${POLICY_LOGS} && \
    chown policy:policy /tmp/policy-install ${POLICY_LOGS} && \
    rmdir ${POLICY_HOME}/etc/ssl && \
    rmdir ${POLICY_HOME}/etc

WORKDIR /tmp/policy-install

COPY /maven/install.zip docker-install.sh do-start.sh wait-for-port.sh ./
RUN unzip install.zip && rm install.zip && chown policy * && chmod +x *.sh

USER policy

ENTRYPOINT [ "bash", "./do-start.sh" ]