Use yaml based instead of template based format for objects filtering

This commit is contained in:
Evgeniy L 2015-04-22 14:31:17 +03:00
parent b79127a535
commit 55a5e8821f
2 changed files with 8 additions and 4 deletions

View File

@ -16,7 +16,7 @@ input:
- service_name: keystone-admin
bind: '*:8080'
backends:
'with_items': '{{ with_tags("service/keystone") }}'
'with_tags': ['service/keystone']
'item':
'remote_name': '{{ item.name }}'
'remote_addr': '{{ item.node.ip }}:{{ item.admin_port }}'
@ -24,7 +24,7 @@ input:
- service_name: keystone-pub
bind: '*:8081'
backends:
with_items: '{{ with_tags("service/keystone") }}'
with_tags: ["service/keystone"]
item:
remote_name: '{{ item.name }}'
remote_addr: '{{ item.node.ip }}:{{ item.public_port }}'

View File

@ -9,8 +9,12 @@ actions:
remove: simple/keystone/remove.yml
input:
db_root_password: '{{ first_with_tags("entrypoint/mariadb").root_password }}'
db_host: '{{ first_with_tags("entrypoint/mariadb").node.ip }}'
db_root_password:
first_with_tags: ["entrypoint/mariadb"]
item: '{{ item.root_password }}'
db_host:
first_with_tags: ["entrypoint/mariadb"]
item: '{{ item.node.ip }}'
admin_port: 35357
public_port: 5000
name: keystone-test