From dd6ea520afa882c3e1adb2f4762ed8c9e0bba8e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stig=20Kleppe-J=C3=B8rgensen?= Date: Wed, 17 Jun 2015 10:00:36 +0200 Subject: [PATCH] Add files for creating docker image * Base on a small node image (alpine-node) * Exclude some files from docker build to make the build go faster --- .dockerignore | 5 +++++ Dockerfile | 11 +++++++++++ 2 files changed, 16 insertions(+) create mode 100644 .dockerignore create mode 100644 Dockerfile diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000000..51a5557c62 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,5 @@ +.git +docker-compose.yml +node_modules +artifact.json +finnbuild.json diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000..bd07d5a3fa --- /dev/null +++ b/Dockerfile @@ -0,0 +1,11 @@ +FROM mhart/alpine-node:0.10.38 + +COPY . . + +RUN npm install --production && \ + npm run build + +EXPOSE 4242 +ENTRYPOINT ["npm"] + +CMD ["start"]