Allow for docker-file inheritance
As a user of the fargate command I would like to be able to deploy my different environments using an inheritance/override model that is allowed with the docker-compose command.
eg: fargate service deploy --service foo --cluster bar -f docker-compose.yml -f docker-compose.dev.yml
https://github.com/turnerlabs/fargate/pull/57
Just curious, what problem does the "inheritance/override model" solve for you? Is it sharing environment variables?
could be environment variables or env files. The default yaml could have default env var or env-files and each environment could inherit and override that without copy and paste. It is also useful for shared x-fargate-secrets just to stop the need for copy/paste.
Ok, yeah was going to say that you could use env_file for that.
dev.yml
web:
env_file:
- shared.env
- dev.env
prod.yml
web:
env_file:
- shared.env
- prod.env
That's how we currently do it, (copy/paste style). The other piece that is nice is that this is just how docker-compose works, so it doesn't throw the surprise when it doesn't work ( like it did to me ). So you can just manage these files like normal docker-compose "compositions" vs "almost like a docker-compose behavior". It comes in handy to inherit the ports, the 'fargate.deploy' label, and probably more features could be 'composed' rather than copied around.