Trying to get a custom domain for my Digital Ocean Spaces Bucket, really can’t find any solution…
What I’m doing:
I’ve setup a CNAME at Cloudflare (Name: “files”, Target: bucket-name.sfo2.digitaloceanspaces.com, Proxy: Enabled, SSL/TLS: Full (strict))
I’ve created a Origin Certificate (RSA (2048), Hostnames: files.domain.com, Certificate Validity: 15yrs)
Key Format PEM Copy/Paste Origin Certificate and Private Key to:
DO - Spaces Object Storage - bucket-name/https://bucket-name.sfo2.digitaloceanspaces.com - Settings - CDN Enabled - Edit CDN - +Add a new subdomain certificate - “Bring your own certificate”:
Certificate name* mysslcertificatename
Certificate* -----BEGIN CERTIFICATE----- OrIGINcERtIFIcaTEfrOMcLOUdFLarE -----END CERTIFICATE-----
Private key* -----BEGIN PRIVATE KEY----- prIVAtEkeYfROMcLOUdFLarE -----END PRIVATE KEY-----
Certificate chain <empty>
Subdomain* files https://files.domain.com
I then click the button: “Generate Certificate and Use Subdomain”.
This is what I see in DO - Spaces - Bucket - Settings:

I’ve previously had this setup working, but I suddenly experienced that the my custom domain CNAME was not working properly, so I disabled the CDN for the bucket and tried to enable it again. I’ve tried recreating what I did originally, but I’m not able to make it work.
It looks like there’s an issue with the SSL certificate., but I’m not really sure at this point.
I’d really appreciate some help here
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Heya, @magnusstrand
You can double check the certificate files and make sure the SSL has not expired as well.
Also, please note that you cannot secure a CDN’s subdomain with a CloudFlare Origin CA certificate or with a custom wildcard SSL certificate that you are already using elsewhere in your account. In these cases, add a new custom certificate during the custom subdomain set up for your CDN.
https://docs.digitalocean.com/products/spaces/how-to/customize-cdn-endpoint/
Regards
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.