cortip/isomera

Create a separate worker launch script

Open

#66 opened on Nov 18, 2023

 (0 comments) (0 reactions) (0 assignees)TypeScript (6 forks)auto 404
back-endgood first issue

Repository metrics

Stars
 (19 stars)
PR merge metrics
 (PR metrics pending)

Description

We have 1 Nest.js project for API, we will need workers too, obviously. Implement a way to build and run this app in either API or Worker mode. Create separate build processes, which would allow deploying into separate instances.

How we will be using this later?

Imagine a docker image build with all node and nest.js necessities which would start api project. We would build 2 of those, where one last command will be different - whether it's api or worker/scheduler is started.

We do not want workers running on an actual API server, because that would consume too much memory, would not be scalable properly and would just make it slow. Seaparating it would mean we can run it separately ;)

Acceptance criteria

  • app/api project can be started with scheduler active
  • app/api project can be started with scheduler inactive
  • It is documented in docs/ how it works and how to run in those two modes

Contributor guide