Two-way tunnel for dev env
The dashboard development environment allows you to run the dashboard locally and other cluster components (in particular kratos, hydra and the single-sign-on database) remotely in your (development) cluster. However, traffic between local and remote components can go in one direction only: it's not possible for remote components to call out to local ones. I ran into this limitation when I wanted to implement kratos hooks: kratos would then call a dashboard endpoint after login and after account recovery, but that would then not work in the dev env.
Besides this, the current dev env also has other small problems, like the domain mismatch between localhost
, stackspin_proxy
and your cluster domain, which leads to cookies not being accepted etc. in some situations.
I'm hoping to solve both of these problems by changing the dev env to use a two-way tunnel between the local and remote parts. There's existing tools that help with that, like Tilt, and also Telepresence. I have tried the latter and it took a bit of fiddling but seems to work nicely now, so maybe that's a good candidate.