This is a simple ecommerce application backend built using the microservices architecture. Here's a series of articles I'm writing to document my journey throught the process.
For ease of use and easier maintainability, I've split the docker-compose files into separate based on the type of services they run.
We can setup/initialize all the pre-requisites needed for our app in docker-compose.setup.yml
. These items could include stuff such as database migrations, seed data creation, creating networks and volumes, etc.
docker-compose --file docker-compose.setup.yml up
The docker-compose.deps.yml
file is used to start up all the application level dependencies such as the database, messaging broker, mailing server, etc.
docker-compose --file docker-compose.deps.yml up
The docker-compose.services.yml
is used to start up all the application level dependencies such as the database, messaging broker, mailing server, etc.
docker-compose --file docker-compose.services.yml up
I've only put the Nginx service in the last docker-compose.gateway.yml
. This is the final piece that'll make out app accessible from the outside internet.
docker-compose --file docker-compose.gateway.yml up