-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
Pass sign_key as environment variable #36
Comments
Hi @djohn156 , |
Hello, I made a mistake when starting the caddy server in BASH script. I tested it out again and it worked as intended. Could you verify it for me?
|
I will close this issue and if you have any problems. Please free free to open it again :) |
Hi @ggicci , thanks for the quick response. However, I've not managed to get this working with a RSA256 key. Yet, that does not seem like a bug in the plugin to me - so not reopening the issue. But if you have a working example with an RSA key, I'd appreciate any hint :) |
Hi @djohn156 , you can try this command: CADDY_JWTAUTH_SIGN_KEY="\"$( cat /tmp/test-key.pub.pem )\"" ./caddy run --config /tmp/Caddyfile It worth noting that you have to quote the content of the public key when assigning to the environment variable. Using multi-line content in directives should be quoted by refering to Caddy's doc. full output:
|
Hi @ggicci for anyone else stumbling upon this issue:
|
Hi, this plugin works in principle great and reliable. However, is there any means of passing the sign key as an environment variable? Currently, in our pipelines, we're replacing the sign_key in our caddyfile via sed, but his does not seem like a clean approach. However, we did not succeed in directly passing the sign_key as an environment variable directly to Caddy similar to the approach explained in the docs.
Are we missing something here (if so, any guidance is appreciated and we would love to read something about it in the docs) or would this be an additional feature? In both cases, this would surely help #1
The text was updated successfully, but these errors were encountered: