Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions molecule/default/tasks/awx_replicas_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@

- include_tasks: _test_case_replicas.yml
vars:
expected_web_replicas: 0
expected_task_replicas: 0
expected_web_replicas: 1
expected_task_replicas: 1

####

Expand Down Expand Up @@ -43,8 +43,8 @@

- include_tasks: _test_case_replicas.yml
vars:
expected_web_replicas: 0
expected_task_replicas: 0
expected_web_replicas: 1
expected_task_replicas: 1

####

Expand Down
4 changes: 2 additions & 2 deletions roles/installer/templates/deployments/task.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ metadata:
{{ lookup("template", "../common/templates/labels/common.yaml.j2") | indent(width=4) | trim }}
{{ lookup("template", "../common/templates/labels/version.yaml.j2") | indent(width=4) | trim }}
spec:
{% if task_replicas != '' and task_manage_replicas | bool %}
{% if task_replicas != '' and task_replicas|int != 0 and task_manage_replicas | bool %}
replicas: {{ task_replicas }}
{% elif replicas != '' and task_manage_replicas | bool %}
{% elif replicas != '' and replicas|int != 0 and task_manage_replicas | bool %}
replicas: {{ replicas }}
{% endif %}
selector:
Expand Down
4 changes: 2 additions & 2 deletions roles/installer/templates/deployments/web.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ metadata:
{{ lookup("template", "../common/templates/labels/common.yaml.j2") | indent(width=4) | trim }}
{{ lookup("template", "../common/templates/labels/version.yaml.j2") | indent(width=4) | trim }}
spec:
{% if web_replicas != '' and web_manage_replicas | bool %}
{% if web_replicas != '' and web_replicas|int != 0 and web_manage_replicas | bool %}
replicas: {{ web_replicas }}
{% elif replicas != '' and web_manage_replicas | bool %}
{% elif replicas != '' and replicas|int != 0 and web_manage_replicas | bool %}
replicas: {{ replicas }}
{% endif %}
selector:
Expand Down
Loading