Better Cloudron release rollout
-
And :
location ~ '^/($|settings|app|api)(/|$)' {This is not a system limit issue; this is a data corruption/template bug caused by the update.
Somewhere in the Cloudron Manager's process, a string that should have been plain text (the Nginx regex) was HTML-encoded before being saved to the database. When the Manager writes the config file, it is literally printing HTML code into a plain-text Nginx configuration.
Nginx sees ' and has no idea what it is. Because the characters are invalid, the Nginx parser gets confused and reports that the location directive was never properly opened with a {, even though the { is right there.
-
Sorry, Cloudron team, I'm out of my depth here :
- appsmonitor installed and ran fine on 9.2.0
- it won't start on Cloudron 10.0.5
- uninstalled it and reinstalled it : same issue.
No —
applogs.txtnginx lines contain no'and no'. So apostrophes/entities are not the problem.But the logs do expose the real suspect. Line 417 (
writeAppLocationNginxConfig) shows the generated proxyAuth nginx location:"path":"!regexp:^/(public|health)(/|$)" "location":"~ ^(?!(regexp:\\^/\\(public\\|health\\)\\(/\\|\\$\\)))"Decoded, that location is
~ ^(?!(regexp:\^/\(public\|health\)\(/\|\$\)))— the literalregexp:prefix leaked into the pattern and every char is backslash-escaped, so it matches a string, not a regexp. That is malformed and is what changed between box versions; it is not a'/'issue. -
Hello @timconsidine
I just installed your community app on Cloudron 10.0.5 and also got the same issue.
The latest Cloudron box code that is not yet released does not have this problem.
It should be this commit https://git.cloudron.io/platform/box/-/commit/6705b1c1107ec43ce09eff1945cd84ef9c60ff07 that fixes it the problem which is part of Cloudron 10.1 which is not yet released.
But maybe you can hotfix your box with these changes for now. -
Sorry, Cloudron team, I'm out of my depth here :
- appsmonitor installed and ran fine on 9.2.0
- it won't start on Cloudron 10.0.5
- uninstalled it and reinstalled it : same issue.
No —
applogs.txtnginx lines contain no'and no'. So apostrophes/entities are not the problem.But the logs do expose the real suspect. Line 417 (
writeAppLocationNginxConfig) shows the generated proxyAuth nginx location:"path":"!regexp:^/(public|health)(/|$)" "location":"~ ^(?!(regexp:\\^/\\(public\\|health\\)\\(/\\|\\$\\)))"Decoded, that location is
~ ^(?!(regexp:\^/\(public\|health\)\(/\|\$\)))— the literalregexp:prefix leaked into the pattern and every char is backslash-escaped, so it matches a string, not a regexp. That is malformed and is what changed between box versions; it is not a'/'issue.But the logs do expose the real suspect. Line 417 (
writeAppLocationNginxConfig) shows the generated proxyAuth nginx location:"path":"!regexp:^/(public|health)(/|$)" "location":"~ ^(?!(regexp:\\^/\\(public\\|health\\)\\(/\\|\\$\\)))"Decoded, that location is
~ ^(?!(regexp:\^/\(public\|health\)\(/\|\$\)))— the literalregexp:prefix leaked into the pattern and every char is backslash-escaped, so it matches a string, not a regexp. That is malformed and is what changed between box versions; it is not a'/'issue.That’s literally the bug I reported here: https://forum.cloudron.io/post/129507 ?
And BTW it’s not an issue for my own app using
proxyAuth. -
The nginx validation bug/corruption bug is fixed. To fix it, you can simply delete that bad nginx config file and systemctl restart nginx. Then the dashboard will be up and you can proceed to repair the apps. Unfortunate that a bug in code brings down the whole system.
-
But the logs do expose the real suspect. Line 417 (
writeAppLocationNginxConfig) shows the generated proxyAuth nginx location:"path":"!regexp:^/(public|health)(/|$)" "location":"~ ^(?!(regexp:\\^/\\(public\\|health\\)\\(/\\|\\$\\)))"Decoded, that location is
~ ^(?!(regexp:\^/\(public\|health\)\(/\|\$\)))— the literalregexp:prefix leaked into the pattern and every char is backslash-escaped, so it matches a string, not a regexp. That is malformed and is what changed between box versions; it is not a'/'issue.That’s literally the bug I reported here: https://forum.cloudron.io/post/129507 ?
And BTW it’s not an issue for my own app using
proxyAuth.@necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?
-
The nginx validation bug/corruption bug is fixed. To fix it, you can simply delete that bad nginx config file and systemctl restart nginx. Then the dashboard will be up and you can proceed to repair the apps. Unfortunate that a bug in code brings down the whole system.
The nginx validation bug/corruption bug is fixed.
Thank you @girish
In what cloudron version ?
Do I need https://git.cloudron.io/platform/box/-/commit/6705b1c1107ec43ce09eff1945cd84ef9c60ff07 ?I tried installing appsmonitor on the cloudron demo box and I get the same error.
Apologies, I am not understanding how to deploy the fix.
Seems like I have to wait for10.0.1or hack my box (which I'm not so keen to do). -
I restricted functionality (no public view facility) in my AppsMonitor app so it works with 10.0.5. (Simpler proxyAuth allowed path).
Given the additional functionality I have added to AppsMonitor, the public page (conceived as a status page) may not be a good idea anyway, so I might remove it permanently anyway. Other ways to do a status page.
Will think about it. -
@necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?
@necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?
10.0.5
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login