loadbalancers
Creates, updates, deletes, gets or lists a loadbalancers resource.
Overview​
| Name | loadbalancers |
| Type | Resource |
| Id | ovh.cloud_network.loadbalancers |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | ID of the load balancer |
name | string | Name of the load balancer |
address | object | Address to reach the load balancer |
configuration | object | Information about version of the configuration |
created_at | string (date-time) | Creation date and time of the load balancer (wire: createdAt) |
description | string | Description of the load balancer |
egress_address | object | IPs used by the load balancer to contact backend's servers (wire: egressAddress) |
networking | object | Networking definition |
openstack_region | string | Openstack region where the load balancer is hosted (wire: openstackRegion) |
region | string | Region where the load balancer is hosted |
size | string | Size of the load balancer (L, M, S) |
status | string | Status of a load balancer (APPLYING, CREATED, DELETING, ERROR, FROZEN, RUNNING) |
A load balancer to handle workload
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | ID of the load balancer |
name | string | Name of the load balancer |
address | object | Address to reach the load balancer |
configuration | object | Information about version of the configuration |
created_at | string (date-time) | Creation date and time of the load balancer (wire: createdAt) |
description | string | Description of the load balancer |
egress_address | object | IPs used by the load balancer to contact backend's servers (wire: egressAddress) |
networking | object | Networking definition |
openstack_region | string | Openstack region where the load balancer is hosted (wire: openstackRegion) |
region | string | Region where the load balancer is hosted |
size | string | Size of the load balancer (L, M, S) |
status | string | Status of a load balancer (APPLYING, CREATED, DELETING, ERROR, FROZEN, RUNNING) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | load_balancer_id, service_name | Get a load balancer (Beta version) | |
list | select | service_name | x_pagination_mode | List all load balancer for a tenant (Beta version) |
create | insert | service_name, region | Create a load balancer (Beta version) | |
update | update | load_balancer_id, service_name | Update a load balancer (Beta version) | |
delete | delete | load_balancer_id, service_name | Delete a load balancer (Beta version) |
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"}}) |
load_balancer_id | string (uuid) | Load balancer ID (wire: loadBalancerId) |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
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 load balancer (Beta version)
SELECT
id,
name,
address,
configuration,
created_at,
description,
egress_address,
networking,
openstack_region,
region,
size,
status
FROM ovh.cloud_network.loadbalancers
WHERE load_balancer_id = '{{ load_balancer_id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
List all load balancer for a tenant (Beta version)
SELECT
id,
name,
address,
configuration,
created_at,
description,
egress_address,
networking,
openstack_region,
region,
size,
status
FROM ovh.cloud_network.loadbalancers
WHERE service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
AND x_pagination_mode = '{{ x_pagination_mode }}'
;
INSERT examples​
- create
- Manifest
Create a load balancer (Beta version)
INSERT INTO ovh.cloud_network.loadbalancers (
description,
name,
networking,
openstack_region,
region,
size,
service_name
)
SELECT
'{{ description }}',
'{{ name }}',
'{{ networking }}',
'{{ openstack_region }}',
'{{ region }}' /* required */,
'{{ size }}',
'{{ service_name }}'
RETURNING
id,
name,
address,
configuration,
created_at,
description,
egress_address,
networking,
openstack_region,
region,
size,
status
;
# Description fields are for documentation purposes
- name: loadbalancers
props:
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the loadbalancers resource.
- name: description
value: "{{ description }}"
description: |
Description of the load balancer
- name: name
value: "{{ name }}"
description: |
Name of the load balancer
- name: networking
description: |
Networking definition
value:
egress:
kind: "{{ kind }}"
ingress:
kind: "{{ kind }}"
- name: openstack_region
value: "{{ openstack_region }}"
description: |
Openstack Region where the load balancer is hosted
- name: region
value: "{{ region }}"
description: |
Region where the load balancer is hosted
- name: size
value: "{{ size }}"
description: |
Size of the load balancer
valid_values: ['L', 'M', 'S']
UPDATE examples​
- update
Update a load balancer (Beta version)
UPDATE ovh.cloud_network.loadbalancers
SET
description = '{{ description }}',
name = '{{ name }}',
size = '{{ size }}'
WHERE
load_balancer_id = '{{ load_balancer_id }}' --required
AND service_name = '{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
RETURNING
id,
name,
address,
configuration,
created_at,
description,
egress_address,
networking,
openstack_region,
region,
size,
status;
DELETE examples​
- delete
Delete a load balancer (Beta version)
DELETE FROM ovh.cloud_network.loadbalancers
WHERE load_balancer_id = '{{ load_balancer_id }}' --required
AND service_name = '{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
;