Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Offical apps | Community apps | Demo | Docs | Install
  1. Cloudron Forum
  2. Discuss
  3. Better Cloudron release rollout

Better Cloudron release rollout

Scheduled Pinned Locked Moved Discuss
11 Posts 4 Posters 143 Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • timconsidineT
    timconsidineT
    timconsidine
    App Dev
    wrote last edited by timconsidine
    #2

    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.

    Indie app dev, scratching my itches : communityapps.appx.uk, portfolio at myca.appx.uk

    1 Reply Last reply
    2
    • timconsidineT
      timconsidineT
      timconsidine
      App Dev
      wrote last edited by
      #3

      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.txt nginx 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 literal regexp: 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.

      Indie app dev, scratching my itches : communityapps.appx.uk, portfolio at myca.appx.uk

      necrevistonnezrN 1 Reply Last reply
      0
      • jamesJ
        jamesJ
        james
        Staff
        wrote last edited by
        #4

        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.

        1 Reply Last reply
        2
        • timconsidineT timconsidine

          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.txt nginx 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 literal regexp: 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.

          necrevistonnezrN
          necrevistonnezrN
          necrevistonnezr
          wrote last edited by
          #5

          @timconsidine said:

          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 literal regexp: 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.

          timconsidineT 1 Reply Last reply
          1
          • girishG
            girishG
            girish
            Staff
            wrote last edited by
            #6

            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.

            timconsidineT 1 Reply Last reply
            1
            • necrevistonnezrN necrevistonnezr

              @timconsidine said:

              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 literal regexp: 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.

              timconsidineT
              timconsidineT
              timconsidine
              App Dev
              wrote last edited by
              #7

              @necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?

              Indie app dev, scratching my itches : communityapps.appx.uk, portfolio at myca.appx.uk

              necrevistonnezrN 1 Reply Last reply
              0
              • girishG girish

                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.

                timconsidineT
                timconsidineT
                timconsidine
                App Dev
                wrote last edited by timconsidine
                #8

                @girish said:

                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 for 10.0.1 or hack my box (which I'm not so keen to do).

                Indie app dev, scratching my itches : communityapps.appx.uk, portfolio at myca.appx.uk

                1 Reply Last reply
                1
                • timconsidineT
                  timconsidineT
                  timconsidine
                  App Dev
                  wrote last edited by timconsidine
                  #9

                  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.

                  Indie app dev, scratching my itches : communityapps.appx.uk, portfolio at myca.appx.uk

                  1 Reply Last reply
                  0
                  • girishG
                    girishG
                    girish
                    Staff
                    wrote last edited by
                    #10

                    I think also 20a1e2c955d011a06c89b552f9ca9d1b6a50f14f . I am working my way to 10.1.0, it's going through our CI and it will contain the fixes.

                    1 Reply Last reply
                    2
                    • timconsidineT timconsidine

                      @necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?

                      necrevistonnezrN
                      necrevistonnezrN
                      necrevistonnezr
                      wrote last edited by
                      #11

                      @timconsidine said:

                      @necrevistonnezr what cloudron version are you on ? 9.2.0 ? or 10.0.5 ?

                      10.0.5

                      1 Reply Last reply
                      1

                      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
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • Bookmarks
                      • Search