Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make session cookie 'domain' property configurable #516

Closed
eriklott opened this issue Jun 16, 2020 · 3 comments
Closed

Make session cookie 'domain' property configurable #516

eriklott opened this issue Jun 16, 2020 · 3 comments
Labels
feat New feature or request.

Comments

@eriklott
Copy link

Kratos currently expects that all services within a system architecture live beneath a single host, each on a unique path (e.g. app.myproduct.com/service1, app.myproduct.com/service2, app.myproduct.com/service3...).

Unfortunately, if your application architecture separates services by subdomain (e.g. service1.myproduct.com, service2.myproduct.com, service3.myproduct.com...), Kratos can't be used effectively. CloudRun, Heroku, and other "serverless" solutions commonly expose services directly to the public, and don't allow for fronting by a gateway or reverse proxy.

If the Kratos session cookie 'domain' property was made configurable (e.g. domain=myproduct.com), Kratos would be just as useful to all apps, regardless of if they expose their internal services by path or subdomain.

@aeneasr aeneasr added the feat New feature or request. label Jun 17, 2020
@aeneasr aeneasr added this to the v0.5.0-alpha.1 milestone Jun 17, 2020
@aeneasr
Copy link
Member

aeneasr commented Jun 17, 2020

Would you be open to provide a PR for this? If so I'll point you in the right direction. :)

@eriklott
Copy link
Author

I don't have time at the moment, but I'd be happy to take a swing at this next month possibly.

@seunggs
Copy link

seunggs commented Feb 4, 2022

@eriklott Hi looks like this ticket item was implemented in Kratos but I can't seem to set the domain attribute even when I set the Kratos config with the following (I'm using Kratos Helm chart - Kratos version: v0.8.0-alpha.3):

session:
  cookie:
    domain: some-domain.com

Were you able to get this working?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat New feature or request.
Projects
None yet
Development

No branches or pull requests

3 participants