From aa07a56224bfd47febd89f0396ab6a1ec1f335da Mon Sep 17 00:00:00 2001 From: BobCashStory <47117399+BobCashStory@users.noreply.github.com> Date: Tue, 6 Oct 2020 13:09:11 +0200 Subject: [PATCH 1/4] Create Dockerfile --- Dockerfile | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..38c857fe --- /dev/null +++ b/Dockerfile @@ -0,0 +1,27 @@ +FROM node:latest + +WORKDIR /usr/src/app +ENV NODE_ENV production +ENV PORT 9000 +EXPOSE 9000 + +RUN apt-get update \ + && apt-get install -yq \ + gconf-service libasound2 libatk1.0-0 libc6 \ + libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 \ + libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 \ + libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 \ + libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 \ + libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 \ + libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation \ + libappindicator1 libnss3 lsb-release xdg-utils wget \ + && rm -r /var/lib/apt/lists/* + +COPY package.json . +COPY yarn.lock . + +RUN yarn install --frozen-lockfile + +COPY . . + +CMD ["node", "src/index.js"] From 5a9a8a6456fce77d4fa16f303c38e31fd23da0e9 Mon Sep 17 00:00:00 2001 From: BobCashStory <47117399+BobCashStory@users.noreply.github.com> Date: Tue, 6 Oct 2020 13:42:34 +0200 Subject: [PATCH 2/4] Update Dockerfile --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 38c857fe..8badfd61 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,7 +18,7 @@ RUN apt-get update \ && rm -r /var/lib/apt/lists/* COPY package.json . -COPY yarn.lock . +COPY package-lock.json . RUN yarn install --frozen-lockfile From 45a8c46834f58462f5d621377ed6c794a2f24856 Mon Sep 17 00:00:00 2001 From: BobCashStory <47117399+BobCashStory@users.noreply.github.com> Date: Tue, 6 Oct 2020 13:58:20 +0200 Subject: [PATCH 3/4] Update Dockerfile --- Dockerfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 8badfd61..ccdb89bb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,5 @@ -FROM node:latest +FROM node:10 + WORKDIR /usr/src/app ENV NODE_ENV production From 988883281b7f657a67063afcce5e40cd3245dfa3 Mon Sep 17 00:00:00 2001 From: BobCashStory <47117399+BobCashStory@users.noreply.github.com> Date: Wed, 7 Oct 2020 13:46:18 +0200 Subject: [PATCH 4/4] Update README.md --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index 57ac43a8..36ffbfd4 100644 --- a/README.md +++ b/README.md @@ -54,7 +54,6 @@ and requests are direct connections to it. * Heavy pages may cause Chrome to crash if the server doesn't have enough RAM. -* Docker image for this can be found here: https://github.com/restorecommerce/pdf-rendering-srv ## Examples