region_floatingips
Creates, updates, deletes, gets or lists a region_floatingips resource.
Overview​
| Name | region_floatingips |
| Type | Resource |
| Id | ovh.cloud_network.region_floatingips |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | ID of the floating ip |
network_id | string (uuid) | ID of the network (wire: networkId) |
associated_entity | object | Associated entity with the floating ip (wire: associatedEntity) |
ip | string (ipv4) | Value of the floating ip (example: 192.0.2.0) |
region | string | Floating ip region |
status | string | Status of the floating ip (active, down, error) |
A floating ip
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | ID of the floating ip |
network_id | string (uuid) | ID of the network (wire: networkId) |
associated_entity | object | Associated entity with the floating ip (wire: associatedEntity) |
ip | string (ipv4) | Value of the floating ip (example: 192.0.2.0) |
region | string | Floating ip region |
status | string | Status of the floating ip (active, down, error) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | floating_ip_id, region_name, service_name | Get a floating ip on a specific region for a public cloud project | |
list | select | region_name, service_name | List floating ips on a specific region for a public cloud project | |
delete | delete | floating_ip_id, region_name, service_name | Delete a floating ip on a specific region for a public cloud project | |
detach | exec | floatingIpId, regionName, service_name | Detach your floating ip |
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"}}) |
floatingIpId | string (uuid) | Floating ip ID |
floating_ip_id | string (uuid) | Floating ip ID (wire: floatingIpId) |
regionName | string | Region name |
region_name | string | Region name (wire: regionName) |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
SELECT examples​
- get
- list
Get a floating ip on a specific region for a public cloud project
SELECT
id,
network_id,
associated_entity,
ip,
region,
status
FROM ovh.cloud_network.region_floatingips
WHERE floating_ip_id = '{{ floating_ip_id }}' -- required
AND region_name = '{{ region_name }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
List floating ips on a specific region for a public cloud project
SELECT
id,
network_id,
associated_entity,
ip,
region,
status
FROM ovh.cloud_network.region_floatingips
WHERE region_name = '{{ region_name }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
DELETE examples​
- delete
Delete a floating ip on a specific region for a public cloud project
DELETE FROM ovh.cloud_network.region_floatingips
WHERE floating_ip_id = '{{ floating_ip_id }}' --required
AND region_name = '{{ region_name }}' --required
AND service_name = '{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
;
Lifecycle Methods​
EXEC variables use wire (API) names.
- detach
Detach your floating ip
EXEC ovh.cloud_network.region_floatingips.detach
@floatingIpId='{{ floatingIpId }}' --required,
@regionName='{{ regionName }}' --required,
@service_name='{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
;