Fix slow exiting and remove stray 'RUN ls'

master
Sijmen Schoon 5 years ago
parent 52da65967b
commit 3e6cac0210
No known key found for this signature in database
GPG Key ID: DAF7821E067D9C48
  1. 1
      backend/Dockerfile
  2. 5
      backend/src/app.js

@ -6,5 +6,4 @@ RUN yarn install
COPY src src/ COPY src src/
COPY data data/ COPY data data/
RUN ls
CMD ["node", "src/index.js"] CMD ["node", "src/index.js"]

@ -14,9 +14,8 @@ const io = socketIO(server);
app.get('/state', (req, res) => res.send('<pre>' + JSON.stringify(state) + '</pre>')); app.get('/state', (req, res) => res.send('<pre>' + JSON.stringify(state) + '</pre>'));
process.on('SIGINT', function() { process.on('SIGINT', () => process.exit());
process.exit(); process.on('SIGTERM', () => process.exit());
});
module.exports = { module.exports = {
app, server, io app, server, io

Loading…
Cancel
Save