Camunda Identity redirecting to localhost

I’ve deployed a self managed cluster (Docker based - development environment) using the docker compose at -

All containers are up and running (Healthy) and all services (operate, tasklist, keycloak) can be accessed via the VM ip and their exposed ports.

The only issue I have is with camunda identity.
When I try to access the identity app using the : , it redirects to keycloak for authentication.
When the redirect happens, the url point to localhost instead of the VM ip (both base keycloak uri as well as redirect uri).

Is there a config missing which is forcing this behavior.

http://localhost:18080/auth/realms/camunda-platform/protocol/openid-connect/auth?client_id=camunda-identity&redirect_uri=http%3A%2F%2Flocalhost%3A8084%2Fauth%2Flogin-callback&response_type=code&scope=openid+email&state=

** note - I’ve modified the yaml and the .env to use the vm ip instead of localhost.

Hi! I’m having the same issue on 8.2 and 8.3.0-alpha4… how did you manage to solve it?

I manage to solve it by configuring these four variables like this:

  IDENTITY_URL: http://${hostname}:${identity_port}
  IDENTITY_AUTH_PROVIDER_ISSUER_URL: http://${hostname}:${keycloak_port}/auth/realms/camunda-platform
  IDENTITY_CLIENT_ID: camunda-identity
  IDENTITY_CLIENT_SECRET: ${camunda_identity_secret_id}