Add network and vpc to args (#60657)
* Add network and vpc to args network and vpc are needed when create a loadbalancer in a vpc in a recent adquired public ip * version_added in new args
This commit is contained in:
parent
7e22c7482e
commit
477b34c440
1 changed files with 13 additions and 0 deletions
|
@ -104,6 +104,16 @@ options:
|
|||
- "To delete all tags, set a empty list e.g. I(tags: [])."
|
||||
type: list
|
||||
aliases: [ tag ]
|
||||
network:
|
||||
description:
|
||||
- Name of the network.
|
||||
type: str
|
||||
version_added: '2.9'
|
||||
vpc:
|
||||
description:
|
||||
- Name of the VPC.
|
||||
type: str
|
||||
version_added: '2.9'
|
||||
extends_documentation_fragment: cloudstack
|
||||
'''
|
||||
|
||||
|
@ -282,6 +292,7 @@ class AnsibleCloudStackLBRule(AnsibleCloudStack):
|
|||
'cidrlist': self.module.params.get('cidr'),
|
||||
'description': self.module.params.get('description'),
|
||||
'protocol': self.module.params.get('protocol'),
|
||||
'networkid': self.get_network(key='id'),
|
||||
})
|
||||
res = self.query_api('createLoadBalancerRule', **args)
|
||||
|
||||
|
@ -338,6 +349,8 @@ def main():
|
|||
zone=dict(),
|
||||
domain=dict(),
|
||||
account=dict(),
|
||||
vpc=dict(),
|
||||
network=dict(),
|
||||
poll_async=dict(type='bool', default=True),
|
||||
))
|
||||
|
||||
|
|
Loading…
Reference in a new issue