Using Kubernetes Ingress to navigate traffic to Services
Introduction In the previous article, I introduced the basic concepts of Kubernetes Ingress , and how to use Ingress along with related components ( Nginx Ingress Controller and cert-manager ) to automatically issue TLS certificates when deploying HTTPS applications . In this article, I'll show you how to define rules in Ingress to route traffic to different Services based on your needs. Prepare Docker Image First, you'll need a Docker image to get started. You can either use two different Docker images or follow my next instructions to prepare a Docker image . Here's a code block to create a NodeJS server that displays a title based on an environment variable input: import express from 'express' const port = 3000 const title = 'This is NodeJS Typescript Application' const app = express () app . get ( '/' , ( _ , res ) => { res . send (( process ?. env ?. TITLE ?? title ) + '! Current time is ' + Date . now ()) ...