-
Notifications
You must be signed in to change notification settings - Fork 53
feat: add public cloud user modules #111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your PR
| try: | ||
| client.wrap_call("DELETE", | ||
| f"/cloud/project/{service_name}/user/{user_id}") | ||
| except OVHResourceNotFound: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The exception should be catched in the OVH class.
| delay: 5 | ||
| ''' | ||
|
|
||
| RETURN = ''' # ''' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The module returns a json
| description = module.params['description'] | ||
| user_id = module.params['user_id'] | ||
| state = module.params['state'] | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are missing a check mode here
|
|
||
| service_name = module.params['service_name'] | ||
| user_id = module.params['user_id'] | ||
| result = client.wrap_call("GET", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check mode is also missing here
| user_id = module.params['user_id'] | ||
| access = module.params['access'] | ||
| state = module.params['state'] | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing check mode also
| EXAMPLES = ''' | ||
| synthesio.ovh.public_cloud_user_s3credentials: | ||
| service_name: "{{ service_name }}" | ||
| user_id: "{{ user_id }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add an exemple of the access that has to be added?
| ''' | ||
|
|
||
| EXAMPLES = ''' | ||
| synthesio.ovh.public_cloud_user_s3credentials_info: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This module returns credentials, examples should mention a register
| client = OVH(module) | ||
|
|
||
| service_name = module.params['service_name'] | ||
| user_id = module.params['user_id'] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check mode is missing
|
|
||
| EXAMPLES = ''' | ||
| synthesio.ovh.public_cloud_users_info: | ||
| service_name: "{{ service_name }}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The module also returns informations, the example is missing a register
| client = OVH(module) | ||
|
|
||
| service_name = module.params['service_name'] | ||
| result = client.wrap_call("GET", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check mode is missing
Add the following modules: