Yeah, I think I’m going to check if a user exists in Discourse, and if they do, just run the code to set their groups, and if they dont, enqueue setting the user groups in our delayed job queue. This should give it about 30-60 seconds before it runs, and the user will be logged in.
edit: Though, on second thought, I’m not sure I want to risk any race conditions of two jobs overwriting each other. Maybe I’ll just run a batch job every few hours to compare discourse users to my userbase?
I dunno, I feel like there’s no good answer until we can do it via SSO