Tencent Cloud CDN distributes content across edge locations. Adding an SSL certificate enables HTTPS between visitors and the CDN. This guide covers certificate upload, HTTPS settings, and related configuration.
1. Preparation
1. Obtain an SSL/TLS certificate
Before deployment, prepare:
- An SSL certificate issued through CertOne, Tencent Cloud, or another provider
- A certificate file (.crt or .pem)
- A private key file (.key)
- An intermediate certificate chain file, when required
2. Prepare Tencent Cloud CDN
- Tencent Cloud CDN is enabled for your account.
- Add your CDN domain
- Complete the required domain filing if using mainland China nodes
2. Upload the certificate
1. Open the CDN console
- Sign in to the Tencent Cloud console.
- Open the CDN service
- Select Domain management
2. Configure HTTPS
- Locate the target domain
- Click Manage
- Open HTTPS configuration
- Click "Configure".
3. Upload a certificate
Option 1: Bring your own certificate
- Select Custom certificate
- Upload the certificate (.crt or .pem)
- Upload the private key (.key)
- Enter a certificate name
- Click OK
Option 2: Use a Tencent Cloud certificate
- Select the Tencent Cloud certificate option.
- Select an issued certificate
- Click OK
3. HTTPS configuration
1. Enable HTTPS
- Open the HTTPS configuration page
- Enable HTTPS secure acceleration
- Select the uploaded certificate
- Click OK
2. Redirect HTTP requests to HTTPS
- Open the HTTPS configuration page
- Enable Force HTTP to HTTPS
- Choose the redirect type (301 or 302)
- Click OK
3. TLS versions
- Open the HTTPS configuration page
- Select TLS versions; use TLS 1.2 and 1.3
- Click OK
4. Automate deployment with CertOne
1. Create a deployment node
- Sign in to CertOne
- Open Deployment nodes
- Click Create deployment node
- Select "Tencent Cloud CDN".
2. Configure API access
- Create an API key in Tencent Cloud.
- Ensure that the key has the required CDN permissions.
- Add the Tencent Cloud authorization in CertOne.
- Test the connection
3. Associate a certificate
- Select the certificate to deploy
- Select the deployment node
- Enable automatic deployment
- Renewed certificates will be deployed to the CDN automatically
5. Optimize the configuration
1. Caching
Static resources:
- Set appropriate cache lifetimes for static resources
- Improve HTTPS delivery speed
HTTPS caching:
- Enable caching for HTTPS content
- Reduce requests to the origin
2. Compression
Enable compression:
- Enable Gzip or Brotli
- Reduce transferred data
- Improve HTTPS delivery speed
3. HTTP/2
Enable HTTP/2:
- Enable HTTP/2 in the CDN configuration where available.
- Improve HTTPS performance
- No additional configuration is needed where enabled by default
Verify the configuration
1. Check HTTPS access
- Visit https://your-domain.com
- Inspect the browser's connection security indicator
- Confirm the certificate details
2. Check redirects
- Visit http://your-domain.com
- Confirm that it redirects to HTTPS
- Check the response status (301 for a permanent redirect)
3. Use a TLS testing tool
- Visit https://www.ssllabs.com/ssltest/
- Enter your domain
- Review the TLS configuration grade
7. Common issues
1. Certificate upload fails
Possible causes:
- Incorrect certificate format
- Mismatched private key
- Incomplete certificate chain
Resolution:
- Check the certificate format
- Confirm that the certificate matches the private key
- Use the complete certificate chain
2. HTTPS is inaccessible
Possible causes:
- The certificate was not uploaded correctly
- HTTPS is disabled
- DNS resolution problems
Resolution:
- Check the certificate configuration
- Confirm HTTPS is enabled
- Check DNS resolution
3. Certificate renewal
Manual renewal:
- Obtain a new certificate
- Upload the replacement certificate to the CDN
- Update the HTTPS configuration
Automatic renewal:
- Use CertOne automatic deployment
- Deploy renewed certificates to the CDN automatically
Best practices
1. Certificate management
- ✅ Use CertOne automatic deployment
- ✅ Set certificate expiration reminders
- ✅ Check certificate status regularly
2. Performance optimization
- ✅ Enable HTTP/2
- ✅ Configure caching policies
- ✅ Enable compression
3. Security configuration
- ✅ Use secure TLS protocols
- ✅ Enable HTTP-to-HTTPS redirects
- ✅ Configure security response headers
Conclusion
Deploying a certificate to Tencent Cloud CDN enables HTTPS for edge delivery. Follow the steps above to upload the certificate and verify the resulting configuration.
Key points:
- ✅ Upload the certificate to the CDN
- ✅ Enable HTTPS secure acceleration
- ✅ Configure HTTP-to-HTTPS redirects
- ✅ Use CertOne automatic deployment
CertOne supports automatic certificate deployment to Tencent Cloud CDN, simplifying renewal and rollout.