oslo_config_validator: Setting container network to none

When spinning a container, podman_container defaults network to bridge
as opposed to docker_container that defaults to none.

This causes "Missing CNI default network" errors and doesn't run the
oslo-config-validator command as expected.

Change-Id: I4faeab61421a9dbd6e5e2ea92c7e64ab1467453b
(cherry picked from commit 9311c11823)
(cherry picked from commit bc692be30d)
(cherry picked from commit 16c6893280)
(cherry picked from commit 5f949e3da0)
This commit is contained in:
David Vallee Delisle 2021-07-12 16:21:45 -04:00
parent 379eae2f6a
commit 4640b2286d
2 changed files with 2 additions and 1 deletions

View File

@ -53,6 +53,7 @@ oslo_config_validator_global_ignored_messages:
- 'WARNING:oslo_config.generator:normalizing group name.*'
- 'WARNING:stevedore.named:Could not load .*'
- 'WARNING:root:Deprecated opt .*'
- 'INFO:oslo_utils.netutils:Could not determine default network interface, using .*'
- 'ERROR:root:quotas/quota_[^\s]+ {{ invalid_setting_regex }}'
- 'Error: error configuring network namespace for container'
- '.*Ignoring option because it is part of the excluded patterns. This can be changed with the.*'

View File

@ -110,6 +110,7 @@
detach: false
rm: true
user: "0"
network: none
mount: "type=bind,source={{ oslo_config_validator_work_path }},destination=/oslo_config_validation"
command: "{{ oslo_command }}"
register: podman_container_run
@ -156,7 +157,6 @@
{{ container_name }} validation failed because:
{{ container_run.stderr }}
- name: Printing container run output
when:
- oslo_config_validator_debug | bool