Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[test-operator] Expose nodeSelector and tolerations parameters #1716

Merged
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
6 changes: 6 additions & 0 deletions roles/test_operator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ Execute tests via the [test-operator](https://openstack-k8s-operators.github.io/
* `cifmw_test_operator_dry_run`: (Boolean) Whether test-operator should run or not. Default value: `false`
* `cifmw_test_operator_fail_fast`: (Boolean) Whether the test results are evaluated when each test framework execution finishes or when all test frameworks are done. Default value: `false`
* `cifmw_test_operator_controller_ip`: (String) An ip address of the controller node. Default value: `ansible_default_ipv4.address` which defaults to (`""`).
* `cifmw_test_operator_tolerations`: (Dict) `tolerations` value that is applied to all pods spawned by the test-operator. Default value: `{}`
* `cifmw_test_operator_node_selector`: (Dict) `nodeSelector` value that is applied to all pods spawned by the test-operator. Default value: `{}`

## Tempest specific parameters
* `cifmw_test_operator_tempest_registry`: (String) The registry where to pull tempest container. Default value: `quay.io`
Expand All @@ -42,6 +44,8 @@ Execute tests via the [test-operator](https://openstack-k8s-operators.github.io/
namespace: "{{ cifmw_test_operator_namespace }}"
spec:
containerImage: "{{ cifmw_test_operator_tempest_image }}:{{ cifmw_test_operator_tempest_image_tag }}"
tolerations: "{{ cifmw_test_operator_tolerations | default(omit) }}"
nodeSelector: "{{ cifmw_test_operator_node_selector | default(omit) }}"
tempestRun:
includeList: |
{{ cifmw_test_operator_tempest_include_list | default('') }}
Expand Down Expand Up @@ -81,6 +85,8 @@ Execute tests via the [test-operator](https://openstack-k8s-operators.github.io/
testenv: "{{ cifmw_test_operator_tobiko_testenv }}"
version: "{{ cifmw_test_operator_tobiko_version }}"
pytestAddopts: "{{ cifmw_test_operator_tobiko_pytest_addopts if cifmw_test_operator_tobiko_pytest_addopts is not none else omit }}"
tolerations: "{{ cifmw_test_operator_tolerations | default(omit) }}"
nodeSelector: "{{ cifmw_test_operator_node_selector | default(omit) }}"
# preventCreate: preventCreate is generated by the test_operator role based on the value of cifmw_test_operator_tobiko_prevent_create
# numProcesses: numProcesses is generated by the test_operator role based on the value of cifmw_test_operator_tobiko_num_processes
# privateKey: privateKey is automatically generated by the test_operator role
Expand Down
4 changes: 4 additions & 0 deletions roles/test_operator/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ cifmw_test_operator_tempest_config:
SSHKeySecretName: "{{ cifmw_test_operator_tempest_ssh_key_secret_name | default(omit) }}"
configOverwrite: "{{ cifmw_test_operator_tempest_config_overwrite | default(omit) }}"
networkAttachments: "{{ cifmw_test_operator_tempest_network_attachments }}"
tolerations: "{{ cifmw_test_operator_tolerations | default(omit) }}"
nodeSelector: "{{ cifmw_test_operator_node_selector | default(omit) }}"
tempestRun:
includeList: |
{{ cifmw_test_operator_tempest_include_list | default('') }}
Expand Down Expand Up @@ -94,6 +96,8 @@ cifmw_test_operator_tobiko_config:
testenv: "{{ cifmw_test_operator_tobiko_testenv }}"
version: "{{ cifmw_test_operator_tobiko_version }}"
pytestAddopts: "{{ cifmw_test_operator_tobiko_pytest_addopts if cifmw_test_operator_tobiko_pytest_addopts is not none else omit }}"
tolerations: "{{ cifmw_test_operator_tolerations | default(omit) }}"
nodeSelector: "{{ cifmw_test_operator_node_selector | default(omit) }}"
# preventCreate: preventCreate is generated by the test_operator role based on the value of cifmw_test_operator_tobiko_prevent_create
# numProcesses: numProcesses is generated by the test_operator role based on the value of cifmw_test_operator_tobiko_num_processes
# privateKey: privateKey is automatically by the test_operator role
Expand Down
Loading