diff --git a/Dockerfile b/Dockerfile index 9d28f0e..bebc357 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM node:14 +FROM node:14-alpine # Create app directory WORKDIR /usr/src/app @@ -10,9 +10,16 @@ COPY package*.json ./ RUN npm install +RUN apk add --no-cache python3 bash \ + && ln -sf python3 /usr/bin/python + # Bundle app source COPY . . +RUN python3 -m ensurepip \ + && pip3 install --no-cache --upgrade pip setuptools \ + && pip3 install -r pip-requirements.txt + EXPOSE 8090 CMD [ "npm", "start" ] diff --git a/prestart.js b/prestart.js index 250b96c..7b59967 100644 --- a/prestart.js +++ b/prestart.js @@ -5,9 +5,7 @@ // md changes), it is more efficient in // that we aren't converting MD -> ejs // on EVERY request -const showdown = require('showdown'), - showdownHighlight = require("showdown-highlight"), - fs = require('fs'), +const fs = require('fs'), mkdirp = require('mkdirp'), recipeInputDir = './recipes/', recipeOutputDir = './views/partials/md/recipes/',