-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
JWT Sign Type Fixing (#1771) #1776
Conversation
Added env variable to the jitsi-meet.cfg.lua and referenced it below
Added the possibility of an Env variable "JWT_SIGN_TYPE" in docker-compose.yml
…used the right variable (jitsi#1771)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure "null" as a string will work, we need to check that.
Ok, please do. |
Is possible to run a CI/CD pipeline to test that? |
Alas there is no CI for that :-/ Your change is not going to work though. It will set it to the string "null". And this is what the module code does: https://github.com/jitsi/jitsi-meet/blob/38be09fc5486979ad554d834702cabbaf5062cc0/resources/prosody-plugins/token/util.lib.lua#L100 So I think the way forward is to only set that config option is actually set, and provide no default. |
@saghul what if we take |
You still have the quotes problem. |
@saghul then remove the quotes?... Alternatively, perhaps error out if no value is set otherwise continue? |
Just add a condition and set it to whatever value the env var has, if it's set. |
Let me get this straight - so I need to open up another PR on the Jitsi Meet GitHub to fix this and after that is merged you may merge this PR afterwards? |
No, you can fix it right here. Just do (pseudocode): if .Env.FOO then the_setting = {{ .Env.FOO }} So don't set it unconditionally, thus preserving the default value, if the user didn't set it. |
Don't if conditions require unnecessary computation power and should be avoided for such cases? I think I did what you wanted - |
Or you want smth like?:
|
or you want an or case with a default value? |
No. DONT declare the auxiliary variable now, you can just if the declaration of the actual prosody variable. |
I don't quite get you. Like this on Line 138 (my version)?:
|
Almost. Don't set signature_algorithm at all if the env car is not defined. |
So just the first two lines from the example above then?:
|
Yes! |
…value in var initialization phase for it
Please review this and merge if it's correct ^^ |
Added and exposed the required env variable.