ssls
Creates, updates, deletes, gets or lists a ssls resource.
Overview​
| Name | ssls |
| Type | Resource |
| Id | ovh.hosting_web.ssls |
Fields​
The following fields are returned by SELECT queries:
- get
successful operation
| Name | Datatype | Description |
|---|---|---|
task_id | integer | The task ID working on this Hosted SSL (wire: taskId) |
is_reportable | boolean | If the hostedssl is currently bound to a report (wire: isReportable) |
provider | string | Provider of the Hosted SSL (COMODO, CUSTOM, LETSENCRYPT, SECTIGO) |
regenerable | boolean | Regenerable flag |
status | string | Status of the Hosted SSL (created, creating, deleting, importing, regenerating) |
type | string | Type of the Hosted SSL (CUSTOM, DV, EV) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | service_name | Returns the provider, type and status of the SSL certificate of the hosting. | |
create | insert | service_name | Creates the free Let's Encrypt SSL certificate of the hosting. To import a custom certificate instead, send the certificate, its private key and its chain. | |
delete | delete | service_name | Deletes the SSL certificate of the hosting. | |
regenerate | exec | serviceName | Regenerates the SSL certificate of the hosting. |
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"}}) |
serviceName | string | Service name |
service_name | string | Service name (wire: serviceName) |
SELECT examples​
- get
Returns the provider, type and status of the SSL certificate of the hosting.
SELECT
task_id,
is_reportable,
provider,
regenerable,
status,
type
FROM ovh.hosting_web.ssls
WHERE service_name = '{{ service_name }}' -- required
;
INSERT examples​
- create
- Manifest
Creates the free Let's Encrypt SSL certificate of the hosting. To import a custom certificate instead, send the certificate, its private key and its chain.
INSERT INTO ovh.hosting_web.ssls (
certificate,
chain,
key,
service_name
)
SELECT
'{{ certificate }}',
'{{ chain }}',
'{{ key }}',
'{{ service_name }}'
RETURNING
task_id,
is_reportable,
provider,
regenerable,
status,
type
;
# Description fields are for documentation purposes
- name: ssls
props:
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the ssls resource.
- name: certificate
value: "{{ certificate }}"
description: |
certificate
- name: chain
value: "{{ chain }}"
description: |
certificate chain
- name: key
value: "{{ key }}"
description: |
private key
DELETE examples​
- delete
Deletes the SSL certificate of the hosting.
DELETE FROM ovh.hosting_web.ssls
WHERE service_name = '{{ service_name }}' --required
;
Lifecycle Methods​
EXEC variables use wire (API) names.
- regenerate
Regenerates the SSL certificate of the hosting.
EXEC ovh.hosting_web.ssls.regenerate
@serviceName='{{ serviceName }}' --required
;