Gitlab runner registration fails for KAS behind a ALB with error "status=426 Upgrade Required"
Summary
When using the helm chart to stand up gitlab with kas in EKS and using the AWS ALB Ingress Controller, gitlab-runners configured with the gitlab-runner helm chart cannot register with the error status=426 Upgrade Required.
Steps to reproduce
- Install gitlab using gitlab helm chart.
- Install gitlab-agent using gitlab-agent helm chart (this works even though it uses the same endpoint).
- Install gitlab-runner using gitlab-runner helm chart
Configuration used
(Please provide a sanitized version of the configuration used wrapped in a code block (```yaml))
global:
ingress:
annotations:
alb.ingress.kubernetes.io/backend-protocol: HTTP
alb.ingress.kubernetes.io/group.name: gitlab
alb.ingress.kubernetes.io/listen-ports: '[{"HTTPS": 443}]'
alb.ingress.kubernetes.io/scheme: internet-facing
kubernetes.io/ingress.class: alb
nginx.ingress.kubernetes.io/connection-proxy-header: "keep-alive"
class: none
enabled: true
path: /*
pathType: ImplementationSpecific
provider: aws
tls:
enabled: false
gitlab:
kas:
enabled: true
service:
type: NodePort
ingress:
annotations:
alb.ingress.kubernetes.io/healthcheck-path: /liveness
alb.ingress.kubernetes.io/healthcheck-port: "8151"
alb.ingress.kubernetes.io/healthcheck-protocol: HTTP
alb.ingress.kubernetes.io/load-balancer-attributes: idle_timeout.timeout_seconds=4000,routing.http2.enabled=false
alb.ingress.kubernetes.io/target-group-attributes: stickiness.enabled=true,stickiness.lb_cookie.duration_seconds=86400
alb.ingress.kubernetes.io/target-type: ip
kubernetes.io/tls-acme: "true"
nginx.ingress.kubernetes.io/connection-proxy-header: "keep-alive"
nginx.ingress.kubernetes.io/x-forwarded-prefix: "/path"
nginx-ingress:
enabled: false
Current behavior
The gitlab runner fails to register with the error "ERROR: Registering runner... failed status=426 Upgrade Required"
Expected behavior
The gitlab-runner successfully registers.
Versions
- Chart: 6.2.2
- Platform:
- Cloud: EKS
- Self-hosted: (OpenShift | Minikube | Rancher RKE | ?)
- Kubernetes: (
kubectl version
)- Client: "v1.21.12"
- Server: "v1.21.13-eks-84b4fe6"
- Helm: (
helm version
)- Client: "v3.9.0"
- Server: "v3.9.0"
Relevant logs
(Please provide any relevate log snippets you have collected, using code blocks (```) to format)
from the gitlab-runner:
Merging configuration from template file "/configmaps/config.template.toml"
ERROR: Registering runner... failed runner=GR1348941sR65RqZs status=426 Upgrade Required
PANIC: Failed to register the runner.
Registration attempt 6 of 30
Runtime platform arch=amd64 os=linux pid=80 revision=32fc1585 version=15.2.1
WARNING: Running in user-mode.
WARNING: The user-mode requires you to manually start builds processing:
WARNING: $ gitlab-runner run
WARNING: Use sudo for system-mode:
WARNING: $ sudo gitlab-runner...