OAuth setup with Zitadel #3557
Aurel004
started this conversation in
OAuth Provider Example
Replies: 1 comment 1 reply
-
|
Is this setup still possible following v2.0? I'm having trouble setting up Mealie w/ Zitadel using User Agent/SPA (because there's no secret) and using Web. Mealie itself recognizes my OIDC configuration, but Zitadel does not even see the client ID. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Configuration Example
Let's configure mealie to work with Zitadel
Docs used:
Go to your zitadel console: https://zitadel.mydomain.com/ui/console
Go to Projects and create a new one if needed, mine will be
serverClick on New

Name it

Mealieand select User AgentSelect PKCE

Redirect URIs set the url of mealie and path login:

https://mealie.mydomain.com/loginPost Logout URIs set the url of mealie and path login?direct=1:
https://mealie.mydomain.com/login?direct=1Click Create and copy the ClientId provided in Notepad
To configure the OIDC_ADMIN_GROUP: Users that are in this group (within your IdP) will be seen as admin in Mealie. you will need to configure Roles
Assert Roles on AuthenticationAdmin(this will be the name used for the group name in mealie), a display name and a group (this one is used for hierarchical groups in case you create other groups)Token Settingsand tickUser roles inside ID Tokento add theAdminrole to the response for MealieUser Info inside ID Tokento give your preferred_username and email to MealieGo to your mealie docker-compose.yml file and add the following to environment:
#SSOOIDC_AUTH_ENABLED: true #Enable OIDCOIDC_SIGNUP_ENABLED: false #Allow unknown users for mealieOIDC_CONFIGURATION_URL: https://zitadel.mydomain.com/.well-known/openid-configurationOIDC_CLIENT_ID: XXX@server #ClientId of Step 7OIDC_AUTO_REDIRECT: false #Enable or disable auto-redirect to OIDCOIDC_PROVIDER_NAME: Zitadel #Choose a name, it can be OAuth (default)OIDC_REMEMBER_ME: trueOIDC_ADMIN_GROUP: Admin #The Key name in Step 8OIDC_GROUPS_CLAIM: urn:zitadel:iam:org:project:{projectId}:roles #Replace {projectId} with the Resource Id copied in step 8, you can also put urn:zitadel:iam:org:project:roles instead but might be deprecated in the futureOIDC_USER_CLAIM: email #Default email, so your email in Zitadel must match existing email account in mealie (if OIDC_SIGNUP_ENABLED set to false), it can be changed to preferred_usernameRecreate your container and voilà, you're done
Beta Was this translation helpful? Give feedback.
All reactions