From 453b34cea2f0c12d42fdc88a26d4c706a8b9c258 Mon Sep 17 00:00:00 2001 From: Adam Date: Wed, 8 Jan 2020 14:13:45 +0100 Subject: [PATCH 1/2] zg --- Dockerfile | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/Dockerfile b/Dockerfile index c01f574..5ea0d90 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,13 +1,16 @@ -FROM node:10 -# Create app directory +FROM alpine:latest -WORKDIR / +WORKDIR /usr/src/ -COPY package*.json ./ +RUN cd /usr/src/ -RUN npm install +RUN apk add --update nodejs npm git -COPY . . +RUN git clone https://github.com/orangecoding/fredy.git + +RUN ln -s /usr/src/fredy/conf/ /conf + +RUN cd /usr/src/fredy/ && npm install EXPOSE 9876 From 2f27ce1f37a2ed8062da2441661cbf9f4b3186dc Mon Sep 17 00:00:00 2001 From: Adam Date: Wed, 8 Jan 2020 14:29:41 +0100 Subject: [PATCH 2/2] ffe --- Dockerfile | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 5ea0d90..d9e9682 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,19 +1,19 @@ FROM alpine:latest -WORKDIR /usr/src/ - -RUN cd /usr/src/ +RUN mkdir -p /usr/src/ RUN apk add --update nodejs npm git -RUN git clone https://github.com/orangecoding/fredy.git +RUN cd /usr/src && git clone https://github.com/orangecoding/fredy.git RUN ln -s /usr/src/fredy/conf/ /conf RUN cd /usr/src/fredy/ && npm install +WORKDIR /usr/src/fredy + EXPOSE 9876 VOLUME [ "/conf" ] -CMD node /index.js --no-daemon \ No newline at end of file +CMD node index.js --no-daemon \ No newline at end of file