From 6bd3f6431c431065dc3a77fc44f9867386b6fd6f Mon Sep 17 00:00:00 2001 From: Joshua Westerheide Date: Thu, 9 Mar 2017 14:32:00 +0100 Subject: [PATCH] Added Dockerfile --- Dockerfile | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..448e5a2 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,24 @@ +FROM node:alpine + +# Prepare application +RUN mkdir -p /app + +# Add source code to container +COPY ./ /app + +# Change workdir to applications folder +WORKDIR /app + +# Install brave-sync's dependencies +RUN yarn install \ + && yarn run build + +# Expose default port +EXPOSE 4000 + +# Populate config dir as volume to persist changes +VOLUME /app/server/config + +# Define container command +CMD ["/usr/local/bin/yarn", "run", "start"] +