C Migrating from Traefik Ingress Controller to Annotations Based Generic Ingress Controller
Prerequisites
Here are the prerequisites you need:
- Install annotation-based ingress controller.
- Delete Traefik Ingress Controller. For more information, see Setting Up Automation
Installing Generic Ingress Controller
To install generic ingress controller:
- You can use any annotation-based ingress controller that supports standard Kubernetes ingress API. The samples for NGINX ingressController are provided.
- For installation of NGINX, the sample values are provided under $COMMON_CNTK/samples/charts/nginx. For more information, see Working with Ingress, Ingress Controller, and External Load Balancer
Migrating to Generic Ingress Controller for ATA
To migrate to generic ingress controller for ATA:
- Delete Traefik Ingress Controller. For more information, see Setting Up Automation.
- Download the latest common-cntk, copy the latest applications.yaml file to spec path and retain your old, required values.
- Make sure the value of ingressController in spec path is
GENERIC
.ingressController: "GENERIC"
- Update the loadbalancerport value in applications.yaml with your ingressController loadbalancer or NodePort port.
- Uncomment and provide required ingress annotations and
ingressClassName in applications.yaml file according to your ingress
controller. The samples are provided for NGINX ingress
controller.
ingress: className: "nginx" annotations: nginx.ingress.kubernetes.io/affinity: "cookie" nginx.ingress.kubernetes.io/affinity-mode: "persistent" nginx.ingress.kubernetes.io/session-cookie-name: "nginxingresscookie" nginx.ingress.kubernetes.io/proxy-body-size: "50m" nginx.ingress.kubernetes.io/proxy-buffer-size: 64k
- (Optional) Provide additional annotations under ata.ingress.annotations tag that is specific to ATA.
- Upgrade the ATA
instance.
$COMMON_CNTK/scripts/upgrade-instance.sh -p project -i instance -f $SPEC_PATH/project/instance/applications.yaml -a ata
- Verify if your application is accessible through your ingressController port.
Migrating to Generic Ingress Controller for Message Bus
To migrate to generic ingress controller for Message Bus:
- Download the latest common-cntk, copy the latest applications.yaml file to spec path and retain your old, required values.
- Make sure the value of ingressController in spec path is
GENERIC
.ingressController: "GENERIC"
- If TLS is
True
, update the loadbalancerport value in applications.yaml with your ingressController loadbalancer or NodePort port. - If TLS is
False
, update ingressSslPort inside the kafka-cluster section in applications.yaml with ingressController loadbalancer or NodePort port.ingress: className: "nginx" annotations: nginx.ingress.kubernetes.io/affinity: "cookie" nginx.ingress.kubernetes.io/affinity-mode: "persistent" nginx.ingress.kubernetes.io/session-cookie-name: "nginxingresscookie" nginx.ingress.kubernetes.io/proxy-body-size: "50m" nginx.ingress.kubernetes.io/proxy-buffer-size: 64k
- Uncomment and provide required ingress annotations specific to Kafka cluster and ingressClassName in applications.yaml file according to your ingress Controller. The samples are provided for NGINX ingress controller.
- For Message Bus, annotations given in kafka-cluster section are
mandatory, under kafka-cluster.listeners.ingress.annotations
tag.
kafka-cluster: listeners: ingress: ingressSslPort: annotations: nginx.ingress.kubernetes.io/ingress.allow-http: "false" nginx.ingress.kubernetes.io/backend-protocol: "HTTPS" ingress.kubernetes.io/ssl-passthrough: "true" nginx.ingress.kubernetes.io/ssl-passthrough: "true"
- Upgrade the Message Bus
instance.
$COMMON_CNTK/scripts/upgrade-application.sh -p project -i instance -f $SPEC_PATH/project/instance/applications.yaml -a messaging-bus
- Verify your application is accessible through your ingressController port.
Migrating to Generic Ingress Controller for OAM
To migrate to generic ingress controller for OAM:
- Download the latest common-cntk, copy the latest applications.yaml file to spec path and retain your old, required values.
- Make sure the value of ingressController in spec path is
GENERIC
.ingressController: "GENERIC"
- Update the loadbalancerport value in applications.yaml with your ingressController loadbalancer or NodePort port.
- Uncomment and provide the required ingress annotations and
ingressClassName in applications.yaml file according to your ingress
controller, samples are provided for NGINX ingress
controller.
ingress: className: "nginx" annotations: nginx.ingress.kubernetes.io/affinity: "cookie" nginx.ingress.kubernetes.io/affinity-mode: "persistent" nginx.ingress.kubernetes.io/session-cookie-name: "nginxingresscookie" nginx.ingress.kubernetes.io/proxy-body-size: "50m" nginx.ingress.kubernetes.io/proxy-buffer-size: 64k
- If SSL enabled, provide additional annotations under
oam-server.ingress.annotations
tag.
oam-server: ingress: annotations: nginx.ingress.kubernetes.io/configuration-snippet: | more_clear_input_headers "WL-Proxy-Client-IP" "WL-Proxy-SSL" "X-Custom-Request-Header" ; more_set_input_headers "X-Forwarded-Proto: https"; more_set_input_headers "WL-Proxy-SSL: true"; more_set_input_headers "IS_SSL: ssl";
- Upgrade the OAM
instance.
$COMMON_CNTK/scripts/upgrade-instance.sh -p project -i instance -f $SPEC_PATH/project/instance/applications.yaml -a oam
- Verify your application is accessible through your ingressController port.