mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
Reformat everything.
This commit is contained in:
@@ -91,7 +91,9 @@ function:
|
||||
"""
|
||||
|
||||
from ansible_collections.community.general.plugins.module_utils.scaleway import (
|
||||
SCALEWAY_REGIONS, scaleway_argument_spec, Scaleway
|
||||
SCALEWAY_REGIONS,
|
||||
scaleway_argument_spec,
|
||||
Scaleway,
|
||||
)
|
||||
from ansible.module_utils.basic import AnsibleModule
|
||||
|
||||
@@ -117,10 +119,7 @@ def info_strategy(api, wished_fn):
|
||||
|
||||
def core(module):
|
||||
region = module.params["region"]
|
||||
wished_function = {
|
||||
"namespace_id": module.params["namespace_id"],
|
||||
"name": module.params["name"]
|
||||
}
|
||||
wished_function = {"namespace_id": module.params["namespace_id"], "name": module.params["name"]}
|
||||
|
||||
api = Scaleway(module=module)
|
||||
api.api_path = f"functions/v1beta1/regions/{region}/functions"
|
||||
@@ -132,11 +131,13 @@ def core(module):
|
||||
|
||||
def main():
|
||||
argument_spec = scaleway_argument_spec()
|
||||
argument_spec.update(dict(
|
||||
namespace_id=dict(type='str', required=True),
|
||||
region=dict(type='str', required=True, choices=SCALEWAY_REGIONS),
|
||||
name=dict(type='str', required=True)
|
||||
))
|
||||
argument_spec.update(
|
||||
dict(
|
||||
namespace_id=dict(type="str", required=True),
|
||||
region=dict(type="str", required=True, choices=SCALEWAY_REGIONS),
|
||||
name=dict(type="str", required=True),
|
||||
)
|
||||
)
|
||||
module = AnsibleModule(
|
||||
argument_spec=argument_spec,
|
||||
supports_check_mode=True,
|
||||
@@ -145,5 +146,5 @@ def main():
|
||||
core(module)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user