Skip to content

Commit

Permalink
fix: set current_node_count to 0 if it does not exists
Browse files Browse the repository at this point in the history
  • Loading branch information
RolandSherwin authored and joshuef committed Jan 23, 2024
1 parent 3e6f55d commit b13065a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions resources/ansible/roles/node/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,7 @@

- name: calculate number of nodes to add
set_fact:
nodes_to_add: "{{ node_instance_count | int - current_node_count | int }}"
when: current_node_count is defined
nodes_to_add: "{{ node_instance_count | int - (current_node_count | default(0)) | int }}"

- name: add node services
become: True
Expand Down

0 comments on commit b13065a

Please sign in to comment.