Skip to main content

cdn

Creates, updates, deletes, gets or lists a cdn resource.

Overview​

Namecdn
TypeResource
Idovh.hosting_web.cdn

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
task_idintegerThe task ID working on this CDN (wire: taskId)
domainstringDomain of this CDN
freebooleanWhether CDN is free with the hosting
statusstringStatus of the CDN option (created, creating, deleting, flushing, reopening, suspended, suspending)
typestringType of the CDN
versionstringVersion of the CDN

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectservice_nameReturns the domain, type, version and status of the CDN option, and whether it is free with the hosting.
log_urlexecserviceName, kindGenerates a temporary URL to read the logs of one kind. The URL expires.
service_infos_updateexecserviceName, renewUpdate CDN renewal. Updates the renewal settings of the CDN option: automatic renewal, renewal period and deletion at expiration.
terminateexecserviceNameTerminate 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.

NameDatatypeDescription
api_hoststringThe 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"}})
serviceNamestringThe internal name of your hosting
service_namestringService name (wire: serviceName)

SELECT examples​

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.

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 }}"
}'
;