Skip to content

Commit

Permalink
Make split jobs child count configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
tremble committed Jul 31, 2021
1 parent 5296624 commit a7f747c
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 5 deletions.
1 change: 1 addition & 0 deletions roles/ansible-test-splitter/defaults/main.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
ansible_test_splitter__test_changed: false
ansible_test_splitter__children_prefix: please_adjust_this
ansible_test_splitter__children_count: 5
2 changes: 1 addition & 1 deletion roles/ansible-test-splitter/tasks/split_targets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
python3 /tmp/split_targets.py
-p "{{ ansible_test_splitter__children_prefix }}"
-t "{{ ansible_test_splitter__targets_to_test|default('') }}"
-j 10
-j "{{ ansible_test_splitter__children_count }}"
args:
chdir: "{{ ansible_test_location }}"
register: _result
Expand Down
26 changes: 22 additions & 4 deletions zuul.d/project-templates.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@
- name: github.com/ansible-collections/ansible.netcommon
- name: github.com/ansible-collections/community.aws
- name: github.com/ansible-collections/community.general
- ansible-test-splitter
- ansible-test-splitter:
vars:
ansible_test_splitter__children_count: 10
- ansible-test-cloud-integration-aws-py36_0
- ansible-test-cloud-integration-aws-py36_1
- ansible-test-cloud-integration-aws-py36_2
Expand All @@ -103,7 +105,9 @@
- name: github.com/ansible-collections/ansible.netcommon
- name: github.com/ansible-collections/community.aws
- name: github.com/ansible-collections/community.general
- ansible-test-splitter
- ansible-test-splitter:
vars:
ansible_test_splitter__children_count: 10
- ansible-test-cloud-integration-aws-py36_0
- ansible-test-cloud-integration-aws-py36_1
- ansible-test-cloud-integration-aws-py36_2
Expand All @@ -130,7 +134,9 @@
- name: github.com/ansible-collections/ansible.netcommon
- name: github.com/ansible-collections/ansible.utils
- name: github.com/ansible-collections/community.general
- ansible-test-splitter
- ansible-test-splitter:
vars:
ansible_test_splitter__children_count: 15
- ansible-test-cloud-integration-aws-py36_0
- ansible-test-cloud-integration-aws-py36_1
- ansible-test-cloud-integration-aws-py36_2
Expand All @@ -141,6 +147,11 @@
- ansible-test-cloud-integration-aws-py36_7
- ansible-test-cloud-integration-aws-py36_8
- ansible-test-cloud-integration-aws-py36_9
- ansible-test-cloud-integration-aws-py36_10
- ansible-test-cloud-integration-aws-py36_11
- ansible-test-cloud-integration-aws-py36_12
- ansible-test-cloud-integration-aws-py36_13
- ansible-test-cloud-integration-aws-py36_14
- ansible-galaxy-importer:
voting: false
gate:
Expand All @@ -156,7 +167,9 @@
- name: github.com/ansible-collections/ansible.netcommon
- name: github.com/ansible-collections/ansible.utils
- name: github.com/ansible-collections/community.general
- ansible-test-splitter
- ansible-test-splitter:
vars:
ansible_test_splitter__children_count: 15
- ansible-test-cloud-integration-aws-py36_0
- ansible-test-cloud-integration-aws-py36_1
- ansible-test-cloud-integration-aws-py36_2
Expand All @@ -167,6 +180,11 @@
- ansible-test-cloud-integration-aws-py36_7
- ansible-test-cloud-integration-aws-py36_8
- ansible-test-cloud-integration-aws-py36_9
- ansible-test-cloud-integration-aws-py36_10
- ansible-test-cloud-integration-aws-py36_11
- ansible-test-cloud-integration-aws-py36_12
- ansible-test-cloud-integration-aws-py36_13
- ansible-test-cloud-integration-aws-py36_14
- ansible-galaxy-importer:
voting: false

Expand Down

0 comments on commit a7f747c

Please sign in to comment.