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

Making check for mandatory ovs_dpdk parms #848

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
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
2 changes: 0 additions & 2 deletions roles/edpm_ovs_dpdk/meta/argument_specs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ argument_specs:
options:
edpm_ovs_dpdk_pmd_core_list:
type: str
default: ""
description: OvS DPDK PMD Core list
edpm_ovs_dpdk_lcore_list:
type: str
Expand All @@ -22,7 +21,6 @@ argument_specs:
description: OvS DPDK extra configs
edpm_ovs_dpdk_socket_memory:
type: str
default: ""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vcandapp
Need to remove in default main.yaml file if we need to remove default value.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Already removed

description: OvS DPDK Socket Memory
edpm_ovs_dpdk_revalidator_cores:
type: str
Expand Down
5 changes: 5 additions & 0 deletions roles/edpm_ovs_dpdk/tasks/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
msg: "List of PMD cores cannot be empty - edpm_ovs_dpdk_pmd_core_list"
when: not edpm_ovs_dpdk_pmd_core_list|string or edpm_ovs_dpdk_pmd_core_list == 'null'

- name: Check valid input for edpm_ovs_dpdk_socket_memory
ansible.builtin.fail:
msg: "Socket Memory cannot be empty - edpm_ovs_dpdk_socket_memory"
when: not edpm_ovs_dpdk_socket_memory|string or edpm_ovs_dpdk_socket_memory == 'null'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vcandapp edpm_ovs_dpdk_socket_memory is "" default, so null check is not required.
Instead of failing, can we make default value for this parameter edpm_ovs_dpdk_socket_memory ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


- name: PMD cores config
when: edpm_ovs_dpdk_pmd_core_list|string
block:
Expand Down
Loading