mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-30 15:38:53 +00:00
Reformat everything.
This commit is contained in:
parent
3f2213791a
commit
340ff8586d
1008 changed files with 61301 additions and 58309 deletions
|
|
@ -93,32 +93,31 @@ from ansible_collections.community.general.plugins.module_utils.scaleway import
|
|||
|
||||
|
||||
class ScalewaySecurityGroupInfo(Scaleway):
|
||||
|
||||
def __init__(self, module):
|
||||
super().__init__(module)
|
||||
self.name = 'security_groups'
|
||||
self.name = "security_groups"
|
||||
|
||||
region = module.params["region"]
|
||||
self.module.params['api_url'] = SCALEWAY_LOCATION[region]["api_endpoint"]
|
||||
self.module.params["api_url"] = SCALEWAY_LOCATION[region]["api_endpoint"]
|
||||
|
||||
|
||||
def main():
|
||||
argument_spec = scaleway_argument_spec()
|
||||
argument_spec.update(dict(
|
||||
region=dict(required=True, choices=list(SCALEWAY_LOCATION.keys())),
|
||||
))
|
||||
argument_spec.update(
|
||||
dict(
|
||||
region=dict(required=True, choices=list(SCALEWAY_LOCATION.keys())),
|
||||
)
|
||||
)
|
||||
module = AnsibleModule(
|
||||
argument_spec=argument_spec,
|
||||
supports_check_mode=True,
|
||||
)
|
||||
|
||||
try:
|
||||
module.exit_json(
|
||||
scaleway_security_group_info=ScalewaySecurityGroupInfo(module).get_resources()
|
||||
)
|
||||
module.exit_json(scaleway_security_group_info=ScalewaySecurityGroupInfo(module).get_resources())
|
||||
except ScalewayException as exc:
|
||||
module.fail_json(msg=exc.message)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue