AWS Certificate Rotation Playbook (ALB + CloudFront)
Use this customer-facing playbook when you need to rotate or replace TLS certificates in your AWS BYOC deployment of Digital Twin.
Common triggers:
- Certificate expiration is approaching
- Your organization is rotating CAs or private keys
- You need to add or change domains/SANs
If you want Viven to coordinate the change window with your team, contact your Viven representative or support@viven.ai.
Scope
This playbook covers both certificates used in AWS BYOC:
- Regional ACM certificate in your deployment region (for Application Load Balancer)
- Global ACM certificate in
us-east-1(for CloudFront)
Prerequisites
Before you start:
- You have AWS permissions to manage ACM, ELBv2, and CloudFront
- You have the new certificate(s) ready to request or import
- DNS validation owners are available (if ACM DNS validation is used)
- You have identified your:
- ALB ARN or name
- ALB HTTPS listener ARN (typically 443)
- CloudFront distribution ID
- You have a rollback plan (keep the current certificates active until validation is complete)
Step 1: Create or import the new certificates in ACM
Create/import both certificates first:
1A) Regional certificate (for ALB)
- Region: same region as your ALB
- Covers your stage and production hostname(s)
- Include wildcard entries (for example,
*.yourdomain.com) if wildcard routing is your standard
1B) Global certificate (for CloudFront)
- Region:
us-east-1 - Covers the stage and production CloudFront-facing hostname(s) used by your distribution
CloudFront can only use ACM certificates from us-east-1.
After requesting/importing, wait until each certificate status is Issued.
Step 2: Update the ALB listener certificate
Apply the following steps to all Digital Twin load balancers and their in-scope HTTPS listeners.
- Open AWS Console → EC2 → Load Balancers
- Select a Digital Twin load balancer
- Open Listeners and rules
- Select HTTPS listener (for example
443) - Choose Manage certificates
- Add/select the new ACM certificate
- Set it as the certificate used for inbound TLS
- Save changes
- Repeat for the next Digital Twin load balancer/listener until all are updated
This rotation is complete only after the certificate is updated for every in-scope Digital Twin load balancer and HTTPS listener.
Optional CLI example:
aws elbv2 modify-listener \
--listener-arn <alb-listener-arn> \
--certificates CertificateArn=<new-regional-certificate-arn> \
--region <your-deployment-region>
Step 3: Update the CloudFront viewer certificate
Apply the following steps to all in-scope Digital Twin CloudFront distributions.
- Open AWS Console → CloudFront
- Select a Digital Twin distribution
- Choose Edit
- In Settings, locate Custom SSL certificate
- Select the new ACM certificate from
us-east-1 - Save changes
- Wait for distribution status to return to Deployed
- Repeat for the next Digital Twin distribution until all are updated
CloudFront updates are global and may take several minutes before all edge locations serve the new certificate.
This rotation is complete only after the certificate is updated for every in-scope Digital Twin CloudFront distribution.
Step 4: Validate the new certificates
Run post-change validation for both paths:
- Browser validation on production URL(s)
- API/UI smoke tests for login and core pages
- TLS metadata check (subject/issuer/validity dates), for example:
echo | openssl s_client -connect digitaltwin.yourdomain.com:443 -servername digitaltwin.yourdomain.com 2>/dev/null | openssl x509 -noout -subject -issuer -dates
Confirm:
- Certificate subject/SAN matches expected domain(s)
notAfterreflects the new certificate validity window- No TLS warnings in browser or synthetic checks
Step 5: Rollback plan (if needed)
If validation fails:
- Re-attach the previous certificate on the ALB listener
- Re-select the previous certificate on CloudFront
- Re-validate service health
- Open a support case with Viven including timestamps and impacted domains
Step 6: Cleanup
After successful cutover and a stabilization window:
- Remove old certificates from active listeners/distributions
- Keep retired certs per your audit/retention policy, then delete from ACM
- Update your internal certificate inventory/expiry alerts
Operational recommendations
- Rotate certificates at least 2-4 weeks before expiration
- Avoid changing ALB and CloudFront certs during peak traffic windows
- If your deployment is managed jointly with Viven, notify Viven before production rotation