Skip to main content

vrack_services

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

Overview​

Namevrack_services
TypeResource
Idovh.vrack.vrack_services

Fields​

The following fields are returned by SELECT queries:

successful operation

NameDatatypeDescription
vrackstringvrack name
vrack_servicesstringvrackServices service name (wire: vrackServices)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectservice_name, vrack_servicesGet a vRack Services. Returns the attached vRack Services and its vRack.
listselectservice_namex_pagination_modeList vRack Services. Returns the vRack Services attached to the vRack.
createinsertservice_name, vrack_servicesAttach a vRack Services. Attaches a vRack Services to the vRack. Its subnets and Service Endpoints are then configured with the vRack Services API. Returns the task that performs it.
deletedeleteservice_name, vrack_servicesDetach a vRack Services. Detaches the vRack Services from the vRack. Returns the task that performs it.

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"}})
service_namestringThe internal name of your vrack (wire: serviceName)
vrack_servicesstringvrackServices service name (wire: vrackServices)
x_pagination_modestringSent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode)

SELECT examples​

Get a vRack Services. Returns the attached vRack Services and its vRack.

SELECT
vrack,
vrack_services
FROM ovh.vrack.vrack_services
WHERE service_name = '{{ service_name }}' -- required
AND vrack_services = '{{ vrack_services }}' -- required
;

INSERT examples​

Attach a vRack Services. Attaches a vRack Services to the vRack. Its subnets and Service Endpoints are then configured with the vRack Services API. Returns the task that performs it.

INSERT INTO ovh.vrack.vrack_services (
vrack_services,
service_name
)
SELECT
'{{ vrack_services }}' /* required */,
'{{ service_name }}'
RETURNING
id,
order_id,
service_name,
function,
last_update,
status,
target_domain,
todo_date
;

DELETE examples​

Detach a vRack Services. Detaches the vRack Services from the vRack. Returns the task that performs it.

DELETE FROM ovh.vrack.vrack_services
WHERE service_name = '{{ service_name }}' --required
AND vrack_services = '{{ vrack_services }}' --required
;