add supervisor (#16)

* add supervisor

* fix perms
This commit is contained in:
Dustin Decker 2023-01-29 12:28:20 -08:00 committed by GitHub
parent b1b48104e1
commit 2d197223cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View file

@ -2,6 +2,7 @@ FROM node:16
RUN mkdir /app/
WORKDIR /app/
RUN npm install pm2 -g
COPY front-end/ /app/front-end/
WORKDIR /app/front-end/
@ -25,7 +26,7 @@ COPY docker-entrypoint.sh /app/
RUN chmod +x /app/docker-entrypoint.sh
COPY templates /app/templates
USER 1111
USER node
# Start the server
ENTRYPOINT ["/app/docker-entrypoint.sh"]

View file

@ -1,4 +1,4 @@
#!/usr/bin/env bash
echo "Starting server..."
node server.js
pm2-runtime server.js