mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
casts the bridge id to a str prior to building command (#21805)
This will prevent exception from being raise when calling _vsctl and extending the cmd with the bridge information
This commit is contained in:
parent
08a752faea
commit
1ef0287854
1 changed files with 2 additions and 1 deletions
|
@ -193,7 +193,7 @@ class OVSBridge(object):
|
|||
'''Create the bridge'''
|
||||
cmd = ['add-br', self.bridge]
|
||||
if self.parent and self.vlan: # Add fake bridge
|
||||
cmd += [self.parent, self.vlan]
|
||||
cmd += [self.parent, str(self.vlan)]
|
||||
|
||||
if self.set and self.set_opt:
|
||||
cmd += ["--", "set"]
|
||||
|
@ -296,6 +296,7 @@ class OVSBridge(object):
|
|||
changed = True
|
||||
|
||||
except Exception:
|
||||
raise
|
||||
earg = get_exception()
|
||||
self.module.fail_json(msg=str(earg))
|
||||
# pylint: enable=W0703
|
||||
|
|
Loading…
Reference in a new issue