Hello, I bought the newly created object storage s3 and would like to connect it to Cloudflare but I have a problem with it. namely url as it receives has the following format: s3.site.com/abcd12345:bucketname/file
abcd12345 is an id that is automatically added to the url. Which means the bucket name is actually “abcd12345:bucketname”
The problem is that when I try to add a CNAME record to DNS, an error pops up because I can’t add a character like “:”
Does anyone know how this can be solved differently or even mask the url in any other way?
There are several parts to a URI (check out RFC 3986 for more detail). DNS is only concerned with the Host portion, s3.site.com, so you cannot have part of the path in the DNS entry.
You need to use Virtual Hosting-Style URIs with Custom CNAME to achieve what you are trying to do.
I have object storage s3 this is not aws but other S3. I’m trying to do url masking or add to cdn like Cloudflare however this is not possible due to the bucket name. Storage automatically adds some digits with id and the “:” character to the bucket. It looks like this: s3.objectstorage.com/11111111111111111111:bucket/file
And this is the name of my bucket: 11111111111111111111:bucket
With this character “:” I can’t add the bucket name to dns. Does anyone know how to solve this problem?
Did you read the solution I gave you 10 days ago?
You cannot reference a URL in DNS, so while you can have a CNAME for www.example.com set to s3.objectstorage.com, but you cannot put the rest of your URL into a DNS entry. Your provider should offer a similar solution to that offered by AWS.
Is s3.objectstorage.com just an example? It does not exist in DNS, but objectstorage.com uses Cloudflare nameservers, so you might end up in an Orange-to-Orange problem doing this in any case.
What you wrote doesn’t solve my problem. I do everything in the wasabi s3 tutorial, it is very similar but the problem occurs in my case with the name of the bucket.
That is not a valid character for. DNS record so you need to use something else… what that is you should determine by asking the storage provider.
There are generally two ways to reference a bucket:
The first is what the document you linked to uses and what is needed to put a bucket behind Cloudflare. Your description above uses the second, which you (generally) cannot put behind Cloudflare.
You might be able to do the following:
www.example.com IN CNAME s3.objectstorage.com
Then reference your objects using your bucket name:
There are lots of issues doing this, and it might work on an Enterprise plan with more configuration, but it is a terrible idea in any case.
You following is meaningless, and cannot be done.:
www.example.com IN CNAME s3.objectstorage.com/11111111111111111111:bucket
This topic was automatically closed after 31 days. New replies are no longer allowed.