I think this is the problem in the module:

env = dict(type='list'),
If it were type='dict' we could do:

docker:

    env:

          options: {"foo":"bar","baz":"qux"}

   other_arguments_here: 1234


And basically use full YAML, without any splitting magic.


If someone would like to help test that change, that would be great,
otherwise, please file a github ticket and we can try it.

It would also be nice if we could do it in a compatible way, but this is
probably not be possible.

Docker is new and has broken APIs in the past, we may also have to :)




On Wed, Aug 13, 2014 at 11:51 PM, Dane Lipscombe <d...@lipscombe.com.au>
wrote:

> I use json to compact my docker environment variables, the problem is that
> the docker module parser splits on ',' character to signify a new key/value
> pair, meaning that more than one key doesn't work. eg
>
> docker: env='options={"foo":"bar"}' //ok
>
> docker: env='options={"foo":"bar","baz":"qux"}' //error because of comma
>
> Is it possible to add an escape for the comma, eg '\,' or ',,' ?
>
>
>
>
> Also, where do you see the latest docker module code? I found this link
> but it says its been merged into the main repository.
>
> https://github.com/cove/docker-ansible/blob/master/docker-ansible.py
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ansible-project+unsubscr...@googlegroups.com.
> To post to this group, send email to ansible-project@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/69fe3bf1-6a74-484c-b997-8c07dd229478%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/69fe3bf1-6a74-484c-b997-8c07dd229478%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CA%2BnsWgxHdCM3hAkG-%3D_WE-PYRhcDaune-g0GmKON6TbJ30nZQA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to