summaryrefslogtreecommitdiffstats
path: root/dgbuilder-docker/src/main/docker/Dockerfile
diff options
context:
space:
mode:
authorSingal, Kapil (ks220y) <ks220y@att.com>2021-03-21 23:46:18 -0400
committerSingal, Kapil (ks220y) <ks220y@att.com>2021-03-21 23:46:18 -0400
commit776684f7a5fd32fa09a68070948f68615d7c7cfa (patch)
treeeb17b6fb95370decdc7eedc115be07a6b1e89760 /dgbuilder-docker/src/main/docker/Dockerfile
parent2eeb0ccd7b4c35dfde5a874c8a253f98714d1f60 (diff)
Refactoring DockerFile
Combine multiple RUN statements to reduce image layers Issue-ID: CCSDK-3226 Signed-off-by: Singal, Kapil (ks220y) <ks220y@att.com> Change-Id: Iebd8e0954eda108a409752b3e6e802a03e429c61
Diffstat (limited to 'dgbuilder-docker/src/main/docker/Dockerfile')
-rw-r--r--dgbuilder-docker/src/main/docker/Dockerfile17
1 files changed, 7 insertions, 10 deletions
diff --git a/dgbuilder-docker/src/main/docker/Dockerfile b/dgbuilder-docker/src/main/docker/Dockerfile
index 974647e8..a2b9291e 100644
--- a/dgbuilder-docker/src/main/docker/Dockerfile
+++ b/dgbuilder-docker/src/main/docker/Dockerfile
@@ -2,25 +2,22 @@
FROM onap/ccsdk-alpine-j11-image:${project.docker.latestfulltag.version}
MAINTAINER CCSDK Team (onap-discuss@lists.onap.org)
-# Create non-root user
USER root
-RUN addgroup -S dgbuilder && adduser -S dgbuilder -G dgbuilder
-RUN apk --no-cache add curl
-#RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
-RUN apk add gcc g++ make ncurses
+RUN addgroup -S dgbuilder && adduser -S dgbuilder -G dgbuilder \
+ && apk --no-cache add curl \
+ && apk add gcc g++ make ncurses \
+ && apk update && apk add yarn nodejs \
+ && node --version
-# copy onap
COPY --chown=dgbuilder:dgbuilder opt /opt
-RUN apk update && apk add yarn nodejs
-RUN node --version
+
WORKDIR /opt/onap/ccsdk/dgbuilder
+
# Set the proxy if needed
# RUN npm config set proxy http://your.proxy.com:8080
RUN cd /opt/onap/ccsdk/dgbuilder/ && npm config set strict-ssl false && npm install
#ENTRYPOINT /bin/bash /opt/onap/ccsdk/dgbuilder/start sdnc1.0
-
USER dgbuilder
EXPOSE 3100
-