CLOUD PAAS / KUBERNETES HOSTING

Kubernetes Cluster: Creating Ingresses

This guide has been reviewed and reformatted for Ruk-Com Cloud PaaS. Screens may vary slightly by platform version.

Click or tap a screenshot to view it at its original size.

Objective

This guide explains how to use Kubernetes Cluster: Creating Ingresses on Ruk-Com Cloud PaaS, with ordered procedures and practical verification points.

Before you begin

  • Sign in with an account permitted to manage the relevant environment.
  • Confirm the target environment, region and resources before saving changes.
  • Create a backup or rollback plan before changing a production system.

IngressAs the name suggests, it is a Kubernetes Cluster load balancer that manages external access to services, provides SSL termination, and virtual hosting. It is managed through a set of rules (spec) that match all incoming requests.

Tips :
Compared to the services disclosed throughNodePort, ingress is a more efficient option but also more complex. It is most useful when you want to expose multiple services under the same IP address. Ingress is also managed by a controller which has many features available. (out-of-the-box) e.g. (SSL, auth, routing, etc.)

Ingresses inKubernetes Clusterare managed byTraefikingress controller by default, with theHAProxyandNGINXoptions available in the upcoming 1.15.5package version. It watches objects, parses specs/annotations, and translates them into redirect rules.

Ingresses inKubernetes ClusterManaged byTraefikingress controller by default with optionsHAProxyandNGINXAvailable in 1.15.5package versionPerform object observation, parse spec/annotation and translate into redirect rules.

Note:
Unable to change selected ingress controller via Kubernetes management add-on or other automation tools after installation Operations can also be done manually. Please contact support if you need assistance.

The ingress spec is a combination of service path rules, backends and ports. For example, your entrance might look like this.

apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  labels:
    app: myapp
  name: myapp
  annotations:
    kubernetes.io/ingress.class: traefik
    ingress.kubernetes.io/secure-backends: "true"
    traefik.frontend.rule.type: PathPrefixStrip
spec:
  rules:
  - http:
      paths:
      - path: /myapp
        backend:
          serviceName: myapp
          servicePort: 8080

This example shows the myapp service bound to port 8080 on the Kubernetes environment's default domain path with the /myapp suffix (i.e. https://${envName}.${platformDomain.com}/myapp). For more information on configuring ingress rules (including path and subdomain-based routing), see:official documentation