Comment

Comment by runeks

Regarding the "users" table: how are users registered with Keycloak saved to the app DB? I assume this is necessary if I want to use Postgres row-level security. Is Keycloak set up to store newly created users in the app DB?

The article mentions a PostgREST endpoint "/rpc/add_user_if_not_exists". Do I need to set up Keycloak to perform a POST request on this endpoint upon a new user registering via Keycloak?

Or can this be done for all requests by simply executing "api.add_user_if_not_exists()" before all other queries, hereby assuming that whatever is in "request.jwt.claim.sub" has been verified by Keycloak?

parent runeks 5 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton