Merge pull request #48 from rapkin/master
Fixed "ERROR! 'mongodb_replication_params' is undefined"
This commit is contained in:
commit
45da87de3d
|
@ -14,7 +14,7 @@
|
||||||
priority: "{{ item.priority|default(1.0) }}"
|
priority: "{{ item.priority|default(1.0) }}"
|
||||||
when: mongodb_conf_auth and mongodb_replication_params is defined
|
when: mongodb_conf_auth and mongodb_replication_params is defined
|
||||||
with_items:
|
with_items:
|
||||||
- "{{ mongodb_replication_params }}"
|
- "{{ mongodb_replication_params|default([]) }}"
|
||||||
|
|
||||||
- name: Replication configuration without auth
|
- name: Replication configuration without auth
|
||||||
mongodb_replication:
|
mongodb_replication:
|
||||||
|
@ -28,4 +28,4 @@
|
||||||
priority: "{{ item.priority|default(1.0) }}"
|
priority: "{{ item.priority|default(1.0) }}"
|
||||||
when: not mongodb_conf_auth and mongodb_replication_params is defined
|
when: not mongodb_conf_auth and mongodb_replication_params is defined
|
||||||
with_items:
|
with_items:
|
||||||
- "{{ mongodb_replication_params }}"
|
- "{{ mongodb_replication_params|default([]) }}"
|
||||||
|
|
|
@ -11,8 +11,9 @@
|
||||||
host_type: "{{ item.host_type|default('replica') }}"
|
host_type: "{{ item.host_type|default('replica') }}"
|
||||||
hidden: "{{ item.hidden|default(false) }}"
|
hidden: "{{ item.hidden|default(false) }}"
|
||||||
priority: "{{ item.priority|default(1.0) }}"
|
priority: "{{ item.priority|default(1.0) }}"
|
||||||
|
when: mongodb_replication_params is defined
|
||||||
with_items:
|
with_items:
|
||||||
- "{{ mongodb_replication_params }}"
|
- "{{ mongodb_replication_params|default([]) }}"
|
||||||
register: mongodb_replica_init
|
register: mongodb_replica_init
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
|
@ -31,6 +32,7 @@
|
||||||
host_type: "{{ item.host_type|default('replica') }}"
|
host_type: "{{ item.host_type|default('replica') }}"
|
||||||
hidden: "{{ item.hidden|default(false) }}"
|
hidden: "{{ item.hidden|default(false) }}"
|
||||||
priority: "{{ item.priority|default(1.0) }}"
|
priority: "{{ item.priority|default(1.0) }}"
|
||||||
|
when: mongodb_replication_params is defined
|
||||||
with_items:
|
with_items:
|
||||||
- "{{ mongodb_replication_params }}"
|
- "{{ mongodb_replication_params|default([]) }}"
|
||||||
when: mongodb_replica_init|failed
|
when: mongodb_replica_init|failed
|
||||||
|
|
Loading…
Reference in New Issue