mysql_migration_checks
Creates, updates, deletes, gets or lists a mysql_migration_checks resource.
Overview​
| Name | mysql_migration_checks |
| Type | Resource |
| Id | ovh.cloud_database.mysql_migration_checks |
Fields​
The following fields are returned by SELECT queries:
- get
successful operation
| Name | Datatype | Description |
|---|---|---|
result | string | Migration result message |
status | string | Status of the migration check task (done, failed, running, syncing, waiting) |
success | boolean | Success status of the migration check |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | cluster_id, service_name | Get the MySQL migration check status | |
create | insert | cluster_id, service_name, source_host, source_password, source_port, source_ssl, source_username | Create a new MySQL migration check |
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"}}) |
cluster_id | string (uuid) | Cluster ID (wire: clusterId) |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
SELECT examples​
- get
Get the MySQL migration check status
SELECT
result,
status,
success
FROM ovh.cloud_database.mysql_migration_checks
WHERE cluster_id = '{{ cluster_id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
INSERT examples​
- create
- Manifest
Create a new MySQL migration check
INSERT INTO ovh.cloud_database.mysql_migration_checks (
source_host,
source_password,
source_port,
source_ssl,
source_username,
cluster_id,
service_name
)
SELECT
'{{ source_host }}' /* required */,
'{{ source_password }}' /* required */,
{{ source_port }} /* required */,
{{ source_ssl }} /* required */,
'{{ source_username }}' /* required */,
'{{ cluster_id }}',
'{{ service_name }}'
RETURNING
result,
status,
success
;
# Description fields are for documentation purposes
- name: mysql_migration_checks
props:
- name: cluster_id
value: "{{ cluster_id }}"
description: Required parameter for the mysql_migration_checks resource.
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the mysql_migration_checks resource.
- name: source_host
value: "{{ source_host }}"
description: |
Source MySQL host
- name: source_password
value: "{{ source_password }}"
description: |
Source MySQL user password
- name: source_port
value: {{ source_port }}
description: |
Source MySQL port
- name: source_ssl
value: {{ source_ssl }}
description: |
Source MySQL ssl enabler
- name: source_username
value: "{{ source_username }}"
description: |
Source MySQL username