From b288d914b65fa3e4b713c6c39fe71e43393f4b69 Mon Sep 17 00:00:00 2001
From: ManifoldFR <wilson.jallet@gmail.com>
Date: Fri, 31 Aug 2018 17:56:37 +0200
Subject: [PATCH] update Dockerfile some more

---
 .dockerignore |  4 ++--
 Dockerfile    | 19 +++++++++++++++++--
 2 files changed, 19 insertions(+), 4 deletions(-)

diff --git a/.dockerignore b/.dockerignore
index b031331..ddb7f99 100644
--- a/.dockerignore
+++ b/.dockerignore
@@ -1,2 +1,2 @@
-src/
-ldap_connexion_config.json
\ No newline at end of file
+node_modules/
+src/
\ No newline at end of file
diff --git a/Dockerfile b/Dockerfile
index 6efd65c..070a8e8 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,3 +1,18 @@
-FROM node:10.9-alpine
+FROM mhart/alpine-node:10.9
 
-CMD [ "node", "build/bundle.js" ]
+# Create app directory
+WORKDIR /app
+
+# Install app dependencies
+COPY package*.json ./
+
+# Native dependencies
+RUN apk add --no-cache make gcc g++ python
+
+RUN npm install --only=production
+
+# Bundle app source
+COPY . .
+
+EXPOSE 3000
+CMD [ "node", "build/bundle.js" ]
\ No newline at end of file
-- 
GitLab