acls
Creates, updates, deletes, gets or lists an acls resource.
Overview​
| Name | acls |
| Type | Resource |
| Id | ovh.cloud.acls |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
account_id | string | OVH customer unique identifier (wire: accountId) |
type | string | ACL type (readOnly, readWrite) |
Cloud ACL
| Name | Datatype | Description |
|---|---|---|
account_id | string | OVH customer unique identifier (wire: accountId) |
type | string | ACL type (readOnly, readWrite) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | account_id, service_name | Get a project ACL. Returns the access type of one OVHcloud account on the project: read-only or read-write. | |
list | select | service_name | type, x_pagination_mode | List project ACLs. Returns the OVHcloud accounts that have access to the project. Filter by access type with the type parameter. |
create | insert | service_name, account_id, type | Grant access to the project. Gives another OVHcloud account read-only or read-write access to the project. | |
delete | delete | account_id, service_name | Revoke access to the project |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
account_id | string | OVH customer unique identifier (wire: accountId) |
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
type | string | Filter the value of type property (=) |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Get a project ACL. Returns the access type of one OVHcloud account on the project: read-only or read-write.
SELECT
account_id,
type
FROM ovh.cloud.acls
WHERE account_id = '{{ account_id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
List project ACLs. Returns the OVHcloud accounts that have access to the project. Filter by access type with the type parameter.
SELECT
account_id,
type
FROM ovh.cloud.acls
WHERE service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
AND type = '{{ type }}'
AND x_pagination_mode = '{{ x_pagination_mode }}'
;
INSERT examples​
- create
- Manifest
Grant access to the project. Gives another OVHcloud account read-only or read-write access to the project.
INSERT INTO ovh.cloud.acls (
account_id,
type,
service_name
)
SELECT
'{{ account_id }}' /* required */,
'{{ type }}' /* required */,
'{{ service_name }}'
RETURNING
account_id,
type
;
# Description fields are for documentation purposes
- name: acls
props:
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the acls resource.
- name: account_id
value: "{{ account_id }}"
description: |
Deleguates rights to
- name: type
value: "{{ type }}"
description: |
Possible values for ACL type
valid_values: ['readOnly', 'readWrite']
DELETE examples​
- delete
Revoke access to the project
DELETE FROM ovh.cloud.acls
WHERE account_id = '{{ account_id }}' --required
AND service_name = '{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
;