Object Storage Custom Domains
Custom domains allow you to use your own domain names to access your Object Storage buckets instead of the default UpCloud domain. A maximum of 5 custom domains can be added per service.
DNS Records Setup
To attach a custom domain, public access to the service must be enabled and DNS records must contain the following CNAME records.
Assume the service has public endpoint zzzzz.upcloudobjects.com and custom domain to be attached is objects.example.com, these are the expected records under example.com domain:
| Type | Host | Target |
|---|---|---|
| CNAME | objects | zzzzz.upcloudobjects.com |
| CNAME | *.objects | zzzzz.upcloudobjects.com |
| CNAME | _acme-challenge.objects | Domain obtained from DNS challenge request |
Attach custom domain
Attaches a new custom domain to the service identified by {service_uuid}.
Attributes
- Name
domain_name- Type
- string
- Description
Custom domain to be added. Must be a subdomain and consist of 3 to 5 parts such as
objects.example.com. Cannot be root-level domain.
- Name
type- Type
- string
- Description
Type of the custom domain. Currently only
publicis accepted.
Request
curl -X POST https://api.upcloud.com/1.3/object-storage-2/0ab2f83f-03f3-4c48-9a38-0a3e89c6d024/custom-domains \
-u your_username:your_password \
-H "Content-Type: application/json" \
-d '{
"domain_name": "objects.example.com",
"type": "public"
}'
List custom domains
Returns a list of custom domains attached to a service by given {service_uuid}.
Request
curl -X GET https://api.upcloud.com/1.3/object-storage-2/0ab2f83f-03f3-4c48-9a38-0a3e89c6d024/custom-domains \
-u your_username:your_password
Get custom domain details
Returns custom domain details by given {service_uuid} and {domain_name}.
Request
curl -X GET https://api.upcloud.com/1.3/object-storage-2/0ab2f83f-03f3-4c48-9a38-0a3e89c6d024/custom-domains/objects.example.com \
-u your_username:your_password
Modify custom domain
Modifies existing custom domain by given {service_uuid} and {domain_name}.
Attributes
- Name
domain_name- Type
- string
- Description
New modified custom domain. Must be a subdomain and consist of 3 to 5 parts.
- Name
type- Type
- string
- Description
Type of the custom domain. Currently only
publicis accepted.
Request
curl -X PATCH https://api.upcloud.com/1.3/object-storage-2/0ab2f83f-03f3-4c48-9a38-0a3e89c6d024/custom-domains/objects.example.com \
-u your_username:your_password \
-H "Content-Type: application/json" \
-d '{
"domain_name": "new-objects.example.com",
"type": "public"
}'
Delete custom domain
Deletes existing custom domain by given {service_uuid} and {domain_name}.
Request
curl -X DELETE https://api.upcloud.com/1.3/object-storage-2/0ab2f83f-03f3-4c48-9a38-0a3e89c6d024/custom-domains/objects.example.com \
-u your_username:your_password