I’m using Consul in combination with a service registration framework (progrium/registrator Docker image) to play around with distributed service discovery. Plus Ansible to start up my Docker containers, etc. However I’m running into a limitation with the ‘env’ option of the Docker module. The registration framework can allow me to set multiple ‘tags’ for a service, but requires them to be expressed as a single environment variable with comma-separate values, eg.
env=“SERVICE_80_TAGS=master,http”
of course, this falls over because the Docker module is expecting multiple environment variables to be comma separated;
env=“SOME_ENV_A=valueA,SOME_ENV_B=valueB”
Can I get this to work with escaping, or would it be possible to support an alternative separator in env?
env=“SERVICE_80_TAGS=master,http:SOME_ENV_A=valueA:SOME_ENV_B=valueB”