0

I have an django app that hosts images on digitalocean spaces. The images are correctly uploaded to my digital ocean spaces. But when I click on the image it is shown with the digital ocean web address. With CDN and custom domain, I thought the web address for the image will be my custom domain (e.g. media.mydoamin.com) but it is directed to digital ocean's endpoint still. sfo3.digtialoceanspaces.com.

I already included a custom domain url in the settings and added a CNAME record to my domain registry media.mydomain.com to an alias as domainname.sfo3.cdn.digitaloceanspaces.com

I can see the cname record is already updated online. what am I missing?

sdg
  • 701
  • 1
  • 5
  • 12
  • I realized at the class PrivateMediaStorage(S3Boto3Storage): custom_domain = False. The problem is if I remove custom_domain= False it would show the file at media.mydomain.com but access denied. I posted more details here https://stackoverflow.com/questions/74201378/access-denied-for-files-uploaded-to-digital-ocean-private-folder-after-i-added-t – sdg Oct 26 '22 at 00:18

0 Answers0