Open hmil opened 8 years ago
By "main container", do you mean "docker container"? Docker's philosophy isn't really about having one big container running multiple applications, but rather many little ones handling little parts. E.g. a solution would be :
A docker-compose.yml file may look like:
web:
image: courseadvisor/nginx-php
volumes:
- /var/www/courseadvisor/:/var/www/courseadvisor
links:
- mysql:mysql
env_file: mysql.env # mysql credentials
mysql:
build: mysql/
# custom dockerfile and config in the mysql/ subfolder
# for instance it may start from the mysql official image and create the courseadvisor
# DB structure + import the last backup
env_file: mysql.env
mysql-slave:
build: mysql-slave/
# same but with mysql_slave
link:
- mysql:mysql
webhook:
image: webhook/
# custom dockerfile installing node, devtools, and running github webhook
env_file: github.env # github repo url, secret key...
volumes:
- /var/www/courseadvisor/:var/www/courseadvisor
And then docker compose up
to run the whole thing
Yup, my bad I should have made this more clear: Each rectangular box in the diagram represents one container ;)
One way to tie everything together would be to have a main container containing the build tools (ie. npm, grunt, composer...) and having access to the infrastructure repository itself.