Zero-Downtime Migration: From Ingress NGINX to Envoy Gateway
In the world of Kubernetes, ensuring zero downtime during migrations is a critical concern. When transitioning from Ingress NGINX to Envoy Gateway, the challenge lies in maintaining service availability while shifting traffic. This migration approach allows you to run both the Ingress and the HTTPRoute at the same time, using weighted DNS records to manage traffic without a hard cutover. This means you can confidently test the new configuration while still serving requests through the old one.
The process involves using ExternalDNS and AWS Route 53 to set up weighted DNS records. Initially, you assign a high weight to the Ingress and zero to the HTTPRoute. This configuration makes the HTTPRoute live but not yet receiving traffic. Once you’re confident in the new setup, you simply swap the weights. This method avoids the need to create or delete DNS records, making the transition smooth and controlled. For instance, you might set the Ingress weight like this: external-dns.alpha.kubernetes.io/aws-weight: "100" and the HTTPRoute like this: external-dns.alpha.kubernetes.io/aws-weight: "0". After the swap, you can revert easily if any issues arise, as there’s no resource to redeploy or DNS record to recreate.
In production, this method is straightforward but requires careful monitoring during the transition. The rollback process is particularly advantageous, allowing you to revert changes quickly if anything goes wrong. This migration strategy is effective and minimizes risk, but always ensure you have proper observability in place to catch any potential issues early.
Key takeaways
- →Leverage weighted DNS records to manage traffic during migration.
- →Run Ingress and HTTPRoute simultaneously to ensure zero downtime.
- →Use ExternalDNS and AWS Route 53 for effective DNS management.
- →Easily roll back changes by swapping DNS weights if issues arise.
Why it matters
In production environments, maintaining uptime during migrations is non-negotiable. This approach allows teams to transition between systems without impacting user experience, which is critical for service reliability.
Code examples
external-dns.alpha.kubernetes.io/aws-weight: "100"external-dns.alpha.kubernetes.io/aws-weight: "0"# Ingress
external-dns.alpha.kubernetes.io/aws-weight: "0"
#HTTPRoute
external-dns.alpha.kubernetes.io/aws-weight: "100"When NOT to use this
The official docs don't call out specific anti-patterns here. Use your judgment based on your scale and requirements.
Want the complete reference?
Read official docsUnified observability — logs, uptime monitoring, and on-call in one place. Used by 50,000+ engineering teams to ship faster and sleep better.
Try Better Stack free →Seamlessly Access Private Git Repositories in EKS with Argo CD
Unlock the power of Argo CD by integrating it with private Git repositories hosted on AWS. Learn how to set up AWS CodeConnections to create a secure network path for your Git server, ensuring smooth deployment workflows.
Mastering Full Request and Response Logging on Amazon EKS
In a world where compliance is non-negotiable, capturing full request and response data is crucial. Learn how Envoy’s External Processing filter enables this without altering your application code.
Mastering EKS Control Plane Egress: Route Your Traffic with Precision
Amazon EKS now allows you to route Kubernetes control plane traffic through your own VPC, giving you greater control over egress traffic. By enabling CUSTOMER_ROUTED mode, you can ensure that API server calls follow your configured routes and security groups.
Get the daily digest
One email. 5 articles. Every morning.
No spam. Unsubscribe anytime.