-
-
Notifications
You must be signed in to change notification settings - Fork 958
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
How to use Weblate with Azure B2C and custom policy? #7885
Comments
This issue looks more like a support question than an issue. We strive to answer these reasonably fast, but purchasing the support subscription is not only more responsible and faster for your business but also makes Weblate stronger. In case your question is already answered, making a donation is the right way to say thank you! |
The back-end |
It should be What you need is to add the backend to |
@nijel Thank you so much for that hint. How exactly would I do that in my case? version: "3"
services:
weblate:
image: weblate/weblate
tmpfs:
- /app/cache
volumes:
- weblate-data:/app/data
environment:
- REDIS_HOST=cache
- REDIS_PORT=6379
restart: always
depends_on:
- cache
ports:
- 80:8080
cache:
image: redis:6-alpine
restart: always
command: ["redis-server", "--appendonly", "yes"]
volumes:
- redis-data:/data
volumes:
weblate-data: {}
redis-data: {} and all the settings are injected via environment variables (aka Application Settings) in Azure. How would I overwrite the settings? Do I just create a new file AUTHENTICATION_BACKENDS = (
"social_core.backends.azuread_b2c.AzureADB2COAuth2",
"social_core.backends.email.EmailAuth",
"weblate.accounts.auth.WeblateUserBackend",
) and nothing else? Is that it? And how would I put that file in the |
You need to add configuration for it as well starting with |
Yeah, the ones here I guess. But just to clarify again: the Do you have any hint for me what the best way is to bake this file into my Docker Compose setup? |
These need to be in the settings-override.py as well. |
Ah okay. Because until recently (with Azure AD, not B2C) we injected said settings via environment variables (aka Application Settings) in Azure with an additional prefix Is that an alternative way or should I do both, i.e. put |
Yes, for supported backends it can be injected via environment, for anything else, Python settings are used. |
Thank you. I will try to bake this into the Docker Compose file. I hope I get it to work with my cloud environment. Two last questions:
|
For anyone having the same questions and ending up here: |
I have tried the OIDC back-end now and, in principal, it seems to work. Hence, I will close this issue now. However, there is still an OIDC error, but I opened a new issue for this. See #7911. |
The issue you have reported is now resolved. If you don’t feel it’s right, please follow its labels to get a clue for further steps.
|
Describe the issue
We have Azure B2C set up with a custom policy flow. We'd like to use this for login with Weblate. According to this linked article from the documentation, one can use a B2C Tenant with the
WEBLATE_SOCIAL_AUTH_AZUREAD_B2C_OAUTH2_POLICY
environment variable.However, the Weblate documentation does not state what the name of the back-end should be, i.e. the value for the environment variable
WEBLATE_REGISTRATION_ALLOW_BACKENDS
.Should one just use
azuread-tenant-oauth2
or is there something likeazuread-b2c-tenant-oauth2
?I already tried
Steps to reproduce the behavior
No response
Expected behavior
No response
Screenshots
No response
Exception traceback
No response
How do you run Weblate?
Docker container
Weblate versions
No response
Weblate deploy checks
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: