User-Defined Domain Name Configuration
Scenarios
If you want to migrate files from a website to OBS while keeping the website address unchanged, you can bind the website domain name to an OBS bucket, so that you can still use the website address to access the files stored in the bucket.
Assume the domain name of your website is www.example.com and the file you want to migrate to OBS is abc.html. After the file is migrated to OBS, you can use http://www.example.com/abc.html to access it. The steps below describe the configurations:
- Create a bucket on OBS, and upload abc.html to the bucket.
- On OBS Console, bind the domain name www.example.com to the created bucket.
- Access the abc.html file. After the request for http://www.example.com/abc.html reaches OBS, OBS finds the mapping between the www.example.com and the bucket domain name, and redirects the request to the abc.html file stored in the bucket. The essence of this process is that OBS redirects the request to access http://www.example.com/abc.html to http://bucket domain name/abc.html.
Constraints
Bucket versions
- Only buckets with version 3.0 or later support user-defined domain name configuration. To check the bucket version, go to the Overview page of the bucket on OBS Console. Then you can view the bucket version in the Basic Information area.
Number of domain names
- By default, a bucket can have up to 20 user-defined domain names bound.
Functions
- User-defined domain names currently allow requests over only HTTP, but not HTTPS.
If you want to use a bound domain name to access OBS over HTTPS, you need to enable CDN to manage HTTPS certificates.
- A user-defined domain name can be bound to only one bucket.
- Chinese domain names are not supported.
- The suffix of a user-defined domain name can contain 2 to 6 uppercase or lowercase letters.
If an acceleration domain name is also needed, to prevent objects in OBS buckets from being directly downloaded upon access, you need to perform other required operations after the custom domain name and the acceleration domain name have been configured. For details, see With CDN Acceleration Enabled, Why Are the Objects in My OBS Bucket Directly Downloaded When I Access Them?
How to Use
You can configure user-defined domain name binding using OBS Console.
Tool |
Reference |
---|---|
OBS Console |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.