diff --git a/changelogs/fragments/51600-provider_segmentation_id-is-int.yaml b/changelogs/fragments/51600-provider_segmentation_id-is-int.yaml new file mode 100644 index 0000000000..f8a1e4c07f --- /dev/null +++ b/changelogs/fragments/51600-provider_segmentation_id-is-int.yaml @@ -0,0 +1,5 @@ +--- +bugfixes: + - os_network - According to the OpenStack Networking API the attribute + provider:segmentation_id of a network has to be an integer. + (https://github.com/ansible/ansible/issues/51655) diff --git a/lib/ansible/modules/cloud/openstack/os_network.py b/lib/ansible/modules/cloud/openstack/os_network.py index f699b4ac2f..f717707288 100644 --- a/lib/ansible/modules/cloud/openstack/os_network.py +++ b/lib/ansible/modules/cloud/openstack/os_network.py @@ -161,7 +161,7 @@ def main(): external=dict(default=False, type='bool'), provider_physical_network=dict(required=False), provider_network_type=dict(required=False), - provider_segmentation_id=dict(required=False), + provider_segmentation_id=dict(required=False, type='int'), state=dict(default='present', choices=['absent', 'present']), project=dict(default=None), port_security_enabled=dict(default=False, type='bool')