I’m trying to setup a better workflow for our project. The project is architectured as follow:
One of the biggest problem we have is that when we need to work locally on the back-end, we have to:
- configure API 1 (settings, env variables, database, …)
- run API 1
- configure API 2 (settings, env variables, database, …)
- run API 2
- configure the back-end (settings, env variables, databases)
- run the back-end
Obviously, it takes a lot of time to be ready and have to be repeated for every developer who need to work on.
I tried the following solutions:
- Using mock server.
This worked well for the front-end when using mock of the backing because the main concern here is to be compliant with the HTTP routes and display the right datas. About the back-end and the API, it is often not enough because the back-end really need information that a mock server can’t properly simulates.
In order to simplify the local deployment of the differents parts, I used docker for every part. Did a very good job for our CI/CD pipeline (Gitlab) but didn’t really simplify the local deployment. But, I think the main concern isn’t docker, it is the way I implemented it for the local deployment. Every part has its own Dockerfile, and is run by using docker-compose which builds and contains every services needed.
How can I reduce the work needed to configure and run the back-end in local ?