cdn
Creates, updates, deletes, gets or lists a cdn resource.
Overview​
| Name | cdn |
| Type | Resource |
| Id | ovh.hosting_web.cdn |
Fields​
The following fields are returned by SELECT queries:
- get
successful operation
| Name | Datatype | Description |
|---|---|---|
task_id | integer | The task ID working on this CDN (wire: taskId) |
domain | string | Domain of this CDN |
free | boolean | Whether CDN is free with the hosting |
status | string | Status of the CDN option (created, creating, deleting, flushing, reopening, suspended, suspending) |
type | string | Type of the CDN |
version | string | Version of the CDN |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | service_name | Returns the domain, type, version and status of the CDN option, and whether it is free with the hosting. | |
log_url | exec | serviceName, kind | Generates a temporary URL to read the logs of one kind. The URL expires. | |
service_infos_update | exec | serviceName, renew | Update CDN renewal. Updates the renewal settings of the CDN option: automatic renewal, renewal period and deletion at expiration. | |
terminate | exec | serviceName | Terminate the CDN option. Requests the termination of the CDN option. A link to confirm it is sent by email to the administrator contact. |
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 |
|---|---|---|
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"}}) |
serviceName | string | The internal name of your hosting |
service_name | string | Service name (wire: serviceName) |
SELECT examples​
- get
Returns the domain, type, version and status of the CDN option, and whether it is free with the hosting.
SELECT
task_id,
domain,
free,
status,
type,
version
FROM ovh.hosting_web.cdn
WHERE service_name = '{{ service_name }}' -- required
;
Lifecycle Methods​
EXEC variables use wire (API) names.
- log_url
- service_infos_update
- terminate
Generates a temporary URL to read the logs of one kind. The URL expires.
EXEC ovh.hosting_web.cdn.log_url
@serviceName='{{ serviceName }}' --required
@@json=
'{
"kind": "{{ kind }}"
}'
;
Update CDN renewal. Updates the renewal settings of the CDN option: automatic renewal, renewal period and deletion at expiration.
EXEC ovh.hosting_web.cdn.service_infos_update
@serviceName='{{ serviceName }}' --required
@@json=
'{
"renew": "{{ renew }}"
}'
;
Terminate the CDN option. Requests the termination of the CDN option. A link to confirm it is sent by email to the administrator contact.
EXEC ovh.hosting_web.cdn.terminate
@serviceName='{{ serviceName }}' --required
;