Login V2 not working with virtual instance?
Hi, I'm trying to test out the virtual instance functionality, but I'm running into a problem when trying to sign in to the non-default instance.
I'm running the standard docker compose from the docs (https://raw.githubusercontent.com/zitadel/zitadel/main/docs/docs/self-hosting/deploy/docker-compose.yaml), except for the fact that I added a system api user via the
ZITADEL_SYSTEMAPIUSERS
env var.
The default instance works fine. I can go to localhost:8080
and it'll redirect me to :3000
for the login v2 ui, which allows me to login just fine.
I then decided to create a virtual instance via /system/v1/instances/_create
to test the virtual instance system. I gave it the custom domain test.localhost
. The instance creation succeeds, but when I now go to test.localhost:8080
it redirects me to localhost:3000
, which shows a blank http500 page. Even if I try to correct the url to test.localhost:3000
, it still errors out.
I looked in the docker logs and I see the following:
If I had to guess what's happening here I'd say the zitadel instance is looking up the auth request for the wrong virtual instance and is failing because it won't exist for the default instance. That said, I'm not knowledgeable enough about how zitadel works to know how to properly debug or fix this.
If anyone knows how to solve this issue or how to help me debug, help would be much appreciated.
Thanks!3 Replies
Hi @Noah, I'm an AI assistant for ZITADEL. While a team member reviews this question, I'll see if I can find relevant sources for your question.
Answer
I wasn't able to find a direct answer, here are some relevant sources:
1. External ZITADEL Access : This explains how ZITADEL uses the Host header to determine which virtual instance to use, and covers configuration for ExternalDomain, ExternalPort, and ExternalSecure settings.
2. Issue with authorization request details : A similar issue where someone experienced authorization request problems in a KinD cluster setup, with the error suggesting protocol or domain configuration issues.
If you'd like me to click the "Ask for help" button to tag a team member for assistance with this virtual instance configuration issue, let me know!
Feel free to tag @Ask Inkeep with additional questions.
Got it. Tagging @Rajat for additional help.
For what it's worth: this also happens on a kubernetes deployment where the login ui v2 lives at
/ui/v2/login
hello @Noah thanks for reaching out! I will review this with my team and get back to you shortly