aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKanagaraj Manickam <kanagaraj.manickam@huawei.com>2020-09-07 02:35:50 +0000
committerGerrit Code Review <gerrit@onap.org>2020-09-07 02:35:50 +0000
commit78014264d1c30dbadd9e463555d3ae664e562bc6 (patch)
treeab254b6a673329e314e2c5a840b1917a3b50cd5d
parent4be0e47c656ce32a2bc93e4ca4205a806744d35f (diff)
parentf5bd1d9c36266cfa62ac81a7f70e9f9eb7810e41 (diff)
Merge "Optimize the refrepo image"
-rw-r--r--vnfmarket-be/deployment/docker/docker-refrepo/src/main/docker/Dockerfile23
1 files changed, 5 insertions, 18 deletions
diff --git a/vnfmarket-be/deployment/docker/docker-refrepo/src/main/docker/Dockerfile b/vnfmarket-be/deployment/docker/docker-refrepo/src/main/docker/Dockerfile
index 21086fc5..6a9eaa56 100644
--- a/vnfmarket-be/deployment/docker/docker-refrepo/src/main/docker/Dockerfile
+++ b/vnfmarket-be/deployment/docker/docker-refrepo/src/main/docker/Dockerfile
@@ -18,7 +18,7 @@
# 10-basebuild.txt
-FROM ubuntu:20.04
+FROM openjdk:11-jre-slim
ARG DEBIAN_FRONTEND=noninteractive
ENV JAVA_VERSION_MAJOR=11 \
@@ -30,32 +30,19 @@ ENV JAVA_VERSION_MAJOR=11 \
# Install required libraries
RUN apt-get update && apt-get install -y \
curl \
+ procps \
g++ \
make \
nano \
nginx \
nodejs \
npm \
- software-properties-common \
sudo \
unzip \
wget \
- && rm -rf /var/lib/apt/lists/*
-
-# Install Java
-WORKDIR /service
-RUN add-apt-repository ppa:openjdk-r/ppa -y && \
- # update data from repositories
- apt-get update && \
- # Make info file about this build
- printf "Build of java:openjdk-11-jre-headless, date: %s\n" `date -u +"%Y-%m-%dT%H:%M:%SZ"` > /service/java && \
- # install application
- apt-get install -y --no-install-recommends openjdk-11-jre-headless && \
- # fix default setting
- ln -s java-11-openjdk-amd64 /usr/lib/jvm/default-jvm && \
- # remove apt cache from image
- apt-get clean all && \
- rm -rf /var/lib/apt/lists/*
+ && rm -rf /var/lib/apt/lists/* \
+ && sudo mkdir -p /usr/lib/jvm/default-jvm \
+ && sudo ln -s /usr/local/openjdk-11/* /usr/lib/jvm/default-jvm
# Download and set up Tomcat
WORKDIR /service