I then mapped a Route53 domain to it with local.domain.com. When I access local.domain.com, the welcome page loads. when I go to customdomain/realms/master/.well-known/openid-configuration, all the urls look perfect.
Here’s where the issue happens,
when I click on the “Adminstration Console” in the welcome page, I get routed to 0.0.0.0/admin/
If i go to customdomain/admin, I get routed to 0.0.0.0/admin/master/console/.
If i go to customdomain/admin/master/console/ I get routed to keycloak with a Invalid parameter: redirect_uri
I can get the login page by setting the redirect_uri query parameter to 0.0.0.0, but of course when I login, it again goes to 0.0.0.0
I don’t know what to do, I have just been living in trial and error mode for a few days. Help would be much appricated
Hey @fwhenin did you ever get to the bottom of this configuration issue? I’m going onto day two of trying to run keycloak in an eks cluster behind an amazon application loadbalancer and I think I need similar configuration as to what you were looking for in this post.
Sorted out my issue - turned out to be a known issue with the codecentric/keycloakx helm chart. I think after the issue is resolved I’ll be able to migrate some of the variables set in the command field back into easier to manage locations of the helm chart but for now they need to be included there to be set as intended.
ingress:
# If `true`, an Ingress is created
enabled: true
# The name of the Ingress Class associated with this ingress
ingressClassName: "alb"
# The Service port targeted by the Ingress
servicePort: http
# Ingress annotations
annotations:
alb.ingress.kubernetes.io/certificate-arn: arn:aws:acm:aws-region-0:111111111111:certificate/abc-123-4d56-e7fg-8hi9-0-12jkl345m67n, arn:aws:acm:ca-central-1:111111111111:certificate/abc-123-4d56-e7fg-8hi9-0-12jkl345m67n, arn:aws:acm:ca-central-1:111111111111:certificate/abc-123-4d56-e7fg-8hi9-0-12jkl345m67n
alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS":443}]'
alb.ingress.kubernetes.io/load-balancer-attributes: idle_timeout.timeout_seconds=180
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/ssl-redirect: "443"
alb.ingress.kubernetes.io/subnets: subnet-abcd1234,subnet-abcd1234,subnet-abcd1234
alb.ingress.kubernetes.io/success-codes: 200-399
alb.ingress.kubernetes.io/tags: UniqueKey=uniqueValue
alb.ingress.kubernetes.io/target-type: ip
kubernetes.io/ingress.class: alb
# Additional Ingress labels
labels: {}
# List of rules for the Ingress
rules:
-
# Ingress host
host: custom.uri.com
# Paths for the host
paths:
# - path: '{{ tpl .Values.http.relativePath $ | trimSuffix "/" }}/'
- path: '/auth/'
pathType: Prefix
# TLS configuration
tls:
- hosts:
- custom.uri.com
replacecustom.uri with your uri
replace certificiate arns with your own (you probably will have less than my example)
replaceaws-region-0 with the region
replace111111111111 with the account number
replaceabc-123-4d56-e7fg-8hi9-0-12jkl345m67n with the correct identity for your amazon certificate manager certificate to use
replacesubnet-abcd1234 with the subnets you’d like the alb to route
optionallyreplaceUniqueKey=uniqueValue with key value pairs you’d like included on the alb