aboutsummaryrefslogtreecommitdiffstats
path: root/Dockerfile
diff options
context:
space:
mode:
authorLucas, John (jl1315) <jflucas@research.att.com>2017-08-23 18:58:33 +0000
committerJ. F. Lucas <jflucas@research.att.com>2017-08-23 19:05:41 +0000
commit3c1527544df835a831898edbd74a473f027bb855 (patch)
tree2e2cf0c7060b39aec4829dc866fcb2468fa16b77 /Dockerfile
parentbacbd4c6349f9de9c597d309a6c23eced2058a15 (diff)
deployment handler initial seed code
Change-Id: I0bfc86d17edead0114ea0012fb469014e978cd15 Issue-Id: DCAEGEN2-43 Signed-off-by: J. F. Lucas <jflucas@research.att.com>
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile18
1 files changed, 18 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..0daecfc
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,18 @@
+FROM node:6.10.3
+MAINTAINER maintainer
+ENV INSROOT /opt/app
+ENV APPUSER dh
+RUN mkdir -p ${INSROOT}/${APPUSER}/lib \
+ && mkdir -p ${INSROOT}/${APPUSER}/etc \
+ && mkdir -p ${INSROOT}/${APPUSER}/log \
+ && useradd -d ${INSROOT}/${APPUSER} ${APPUSER}
+COPY *.js ${INSROOT}/${APPUSER}/
+COPY *.json ${INSROOT}/${APPUSER}/
+COPY lib ${INSROOT}/${APPUSER}/lib/
+COPY etc/log4js.json ${INSROOT}/${APPUSER}/etc/log4js.json
+WORKDIR ${INSROOT}/${APPUSER}
+RUN npm install --only=production && chown -R ${APPUSER}:${APPUSER} ${INSROOT}/${APPUSER} && npm remove -g npm
+USER ${APPUSER}
+VOLUME ${INSROOT}/${APPUSER}/log
+EXPOSE 8443
+ENTRYPOINT ["/usr/local/bin/node", "deployment-handler.js"]