Put in order · NestJS course · Module 9: Deployment and Infrastructure

Startup Order of Production Services

Arrange the service startup order in docker-compose with depends_on:

Items to put in order

  • api (application waits for dependencies)
  • redis (cache starts after the database)
  • mongodb (the database starts first)
  • nginx (reverse proxy at the end)

You can check the correct answer by solving this task in the CodeWorlds game.