Open fool opened 8 months ago
i think the most reliable route would be with a docker container. i only know how to do that with docker compose ( as per https://github.com/shift-org/shift-docs/blob/beta/docker-compose.yml )
node:
build:
context: .
dockerfile: node.docker
restart: always
but docker will happily watch and reboot the process when needed.
alternatively, express ( which we use ) has some suggestions:
https://expressjs.com/en/advanced/best-practice-performance.html#ensure-your-app-automatically-restarts
forever
seems simplest, the others have features for multiple systems, log rotation, remote control, ... we would just have to choose one and try.
not sure what the best practice is. Need to make sure this setup (both first-run and subsequent restarts) respect settings per https://github.com/shift-org/shift-docs/issues/635