Hello,
I have two machines both running ansible 2.0.0.2 on Ubuntu 14.04.3 LTS. On one machine ( my work machine )
the yaml file works well while on the deployment server it throws an error "ERROR! failed to combine variables, expected dicts but got a 'dict' and a 'AnsibleUnicode'"
---
- hosts: docker_staging
vars:
- web_port: 8008
- identifier: abc
- instance: web
- image_suffix: -web
- enc_key: 0x0
tasks:
- include: tasks/deploy.yaml
There is a group_vars/docker_staging.yaml which contains some variables:
---
nginx_blacklist: yes
nginx_servers:
- {
db_name: sta_abc,
db_pass: password,
db_user: abc_user,
listen: 80,
ssl: off,
proxy_pass: "localhost:8001",
additionals: [
"client_max_body_size 200M;"
]
}
This worked well on my machine but has thrown the above error on the deployment server. However, when I change the main.yaml to use include_vars and rename group_vars to something
else it works:
---
- hosts: docker_staging
vars:
- web_port: 8008
- identifier: abc
- instance: web
- image_suffix: -web
- enc_key: 0x0
tasks:
- include_vars: application_vars/docker_staging.yaml
- include: tasks/deploy.yaml
This is odd behaviour. Any help on this?
Kind regards,
Sascha