-
-
Notifications
You must be signed in to change notification settings - Fork 3.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
certbot error on apache conf file with stringified JSON for SetEnv #7413
Comments
While this is surely a bug because it does not match Apache's parser, you can work around it by single-quoting your JSON. Here's a previous instance of this problem and the solution: https://community.letsencrypt.org/t/certbot-syntax-error-with-report-to-and-nel-header-in-apache-config/97940 |
alexzorin, thank for your reply, Yes I tried the single quotes, unfortunately my JSON parser then failed. My workaround is to regex the string before parsing, but ideally a fix in certbot. |
It would be so great if the Apache project could publish a grammar for their configuration language! @joohoi, are you an appropriate person to look at this at the moment and how would it interact with attempts to replace Certbot's parsing infrastructure? @tim-hogan, thank you for the report, and @alexzorin, thank you for the diagnosis and forum reference. |
We've made a lot of changes to Certbot since this issue was opened. If you still have this issue with an up-to-date version of Certbot, can you please add a comment letting us know? This helps us to better see what issues are still affecting our users. If there is no activity in the next 30 days, this issue will be automatically closed. |
This is still a problem on version (0.31.0-2~deb10u1+ubuntu18.04.1+certbot+3) |
We've made a lot of changes to Certbot since this issue was opened. If you still have this issue with an up-to-date version of Certbot, can you please add a comment letting us know? This helps us to better see what issues are still affecting our users. If there is no activity in the next 30 days, this issue will be automatically closed. |
This problem still exists on version 1.21.0 |
Certbot fails when an apache SetEnv command is used with stringified JSON.
Example line in .conf file:
SetEnv ENV_JSON {"abc":"val1","def":"val2"}
OS Version Linux 4.4.0-142-generic #168-Ubuntu SMP Wed Jan 16 21:00:45 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
Installed Certbot with apt-get install certbot python-certbot-apache
Ran certbot with:
sudo certbot --apache
Error: The error was: PluginError('There has been an error in parsing the file /etc/apache2/sites-enabled/loc.nz.conf on line 101: Syntax error',)
The text was updated successfully, but these errors were encountered: