summaryrefslogtreecommitdiffstats
path: root/packages/policy-gui-docker/src/main/docker/Dockerfile
diff options
context:
space:
mode:
authordanielhanrahan <daniel.hanrahan@est.tech>2021-09-08 17:55:13 +0100
committerdanielhanrahan <daniel.hanrahan@est.tech>2021-09-10 11:47:18 +0100
commit69d300a2132f103162a5e98f68ae4256750ce527 (patch)
treee5cca7b3f647987820a5f55a78490bdc36711238 /packages/policy-gui-docker/src/main/docker/Dockerfile
parent4ee6cfe3c0c507370118348d782b14a09e1b3c53 (diff)
Remove CLAMP_REST_URL variable from Docker image
Remove redundant CLAMP_REST_URL environment variable Update README to remove references to CLAMP_REST_URL Group Dockerfile COPY commands to reduce image layers Issue-ID: POLICY-3639 Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech> Change-Id: Ia6947a6681875167dfc63b0ffd19f7dc6faad6d4
Diffstat (limited to 'packages/policy-gui-docker/src/main/docker/Dockerfile')
-rw-r--r--packages/policy-gui-docker/src/main/docker/Dockerfile25
1 files changed, 8 insertions, 17 deletions
diff --git a/packages/policy-gui-docker/src/main/docker/Dockerfile b/packages/policy-gui-docker/src/main/docker/Dockerfile
index 681a58d..0e8bcc2 100644
--- a/packages/policy-gui-docker/src/main/docker/Dockerfile
+++ b/packages/policy-gui-docker/src/main/docker/Dockerfile
@@ -26,30 +26,21 @@ ARG POLICY_LOGS=/var/log/onap/policy/gui
ENV POLICY_LOGS=$POLICY_LOGS
ENV POLICY_HOME=$POLICY_HOME/gui
-ENV CLAMP_REST_URL=http://0.0.0.0
RUN mkdir -p $POLICY_HOME $POLICY_LOGS $POLICY_HOME/bin $POLICY_HOME/lib && \
chown -R policy:policy $POLICY_HOME $POLICY_LOGS && \
apk update && \
- apk add --no-cache gettext nginx
+ apk add --no-cache nginx
-WORKDIR $POLICY_HOME
-COPY policy-gui.sh ./bin/
-COPY /maven/gui-editor-apex-uber.jar ./lib/
-COPY /maven/gui-pdp-monitoring-uber.jar ./lib/
-COPY etc/ssl/clamp.key /etc/ssl/clamp.key
-COPY etc/ssl/clamp.pem /etc/ssl/clamp.pem
-COPY nginx/nginx.conf /etc/nginx/nginx.conf
-COPY nginx/default.conf.template /etc/nginx/templates/default.conf.template
-COPY nginx/index.html /usr/share/nginx/html/
-ADD /maven/gui-clamp-html.tar.gz /usr/share/nginx/html/
-ADD /maven/gui-pdp-monitoring-html.tar.gz /usr/share/nginx/html/
-RUN rm /etc/nginx/conf.d/default.conf && \
- ln -sf /dev/stdout /var/log/nginx/access.log && \
+COPY --chown=policy:policy etc/ /etc/
+COPY --chown=policy:policy policy-gui.sh $POLICY_HOME/bin/
+COPY --chown=policy:policy /maven/*.jar $POLICY_HOME/lib/
+ADD --chown=policy:policy index.html /maven/*-html.tar.gz /usr/share/nginx/html/
+RUN ln -sf /dev/stdout /var/log/nginx/access.log && \
ln -sf /dev/stderr /var/log/nginx/error.log && \
touch /var/run/nginx.pid && \
- chown -R policy:policy . /etc/nginx /usr/share/nginx /var/lib/nginx /var/log/nginx /var/run/nginx.pid && \
- chmod 755 bin/*.sh
+ chown -R policy:policy /etc/nginx /usr/share/nginx /var/lib/nginx /var/log/nginx /var/run/nginx.pid && \
+ chmod 755 $POLICY_HOME/bin/*.sh
USER policy
WORKDIR $POLICY_HOME/bin