Open shift route and Ingress - unix1998/technical_notes GitHub Wiki

You're absolutely correct! OpenShift 4.X offers both Ingress and Route functionalities for exposing services to external traffic. Here's a breakdown of how they differ and how OpenShift implements Ingress (not Route):

OpenShift Route vs. Ingress:

  • Route: This is the native way of exposing services in OpenShift. It provides basic routing functionality along with additional features like:

    • TLS termination and re-encryption (increased security)
    • Weighted backends (traffic splitting)
    • Wildcard domain support
    • Integration with OpenShift security features
  • Ingress: Introduced in OpenShift 3.10, Ingress objects offer a more standardized approach to routing, similar to what you find in vanilla Kubernetes. These Ingress objects define rules for routing external traffic based on paths, hostnames, or headers.

How OpenShift Implements Ingress:

  • OpenShift Router: Unlike relying on separate Ingress controllers like Nginx or Traefik, OpenShift leverages its built-in highly-tuned HAProxy router to handle Ingress objects.
  • Translation Process: When you create an Ingress resource in OpenShift, it gets translated into a corresponding Route object behind the scenes. This translation ensures compatibility with existing Ingress configurations from other Kubernetes environments.
  • Benefits: This approach offers a streamlined experience for managing external traffic within OpenShift. You can leverage the familiar Ingress resource structure while benefiting from the capabilities of the OpenShift router.

Key Points:

  • OpenShift prioritizes Routes for exposing services, offering additional features and security integration.
  • Ingress objects provide compatibility with external Kubernetes configurations, translated into Routes for execution by the OpenShift router.
  • You don't need to deploy separate Ingress controllers like Nginx or Traefik in OpenShift 4.X.

Additional Considerations:

  • While OpenShift translates Ingress objects to Routes, there might be some minor configuration differences to consider when migrating existing Ingress configurations from other platforms.
  • It's generally recommended to use Routes for most scenarios within OpenShift to take advantage of its built-in security features and functionalities.

In summary, OpenShift's implementation of Ingress utilizes the built-in HAProxy router for routing, translating Ingress objects into Routes for seamless operation within the OpenShift environment.