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

Apps - Status | Demo | Docs | Install
  1. Cloudron Forum
  2. Castopod
  3. Analytics - Location not applicable because of local ip

Analytics - Location not applicable because of local ip

Scheduled Pinned Locked Moved Solved Castopod
10 Posts 2 Posters 2.7k Views 2 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.
  • luckowL Offline
    luckowL Offline
    luckow
    translator
    wrote on last edited by
    #1

    Maybe it's just me. The analytics dashboard location is empty. The hints are pointing towards a local IP address instead of the listener's IP. Is there a way to "redirect" the listener's IP address to Castopod?

    d3b520c5-f2f9-4529-b151-cf9233b0683c-image.png

    Pronouns: he/him | Primary language: German

    1 Reply Last reply
    1
    • nebulonN Away
      nebulonN Away
      nebulon
      Staff
      wrote on last edited by
      #8

      So the fix is to add app.proxyIPs.0="172.18.0.0/16" to the env file, will be part of next package release.

      luckowL 1 Reply Last reply
      0
      • nebulonN Away
        nebulonN Away
        nebulon
        Staff
        wrote on last edited by nebulon
        #2

        without further investigation, maybe the app needs support for reverse proxy X-Forwarded-For header

        1 Reply Last reply
        0
        • nebulonN nebulon marked this topic as a question on
        • nebulonN Away
          nebulonN Away
          nebulon
          Staff
          wrote on last edited by
          #3

          Looks like we have to set proxyIPs as mentioned in https://code.castopod.org/adaures/castopod/-/blob/develop/app/Config/App.php#L179

          1 Reply Last reply
          1
          • nebulonN Away
            nebulonN Away
            nebulon
            Staff
            wrote on last edited by nebulon
            #4

            @luckow where is that analytics page in the app? I can't seem to find that to test a fix.

            You could also put app.proxyIPs="172.18.0.1" into /app/data/env and restart the app to see if this fixes it

            luckowL 2 Replies Last reply
            0
            • nebulonN nebulon

              @luckow where is that analytics page in the app? I can't seem to find that to test a fix.

              You could also put app.proxyIPs="172.18.0.1" into /app/data/env and restart the app to see if this fixes it

              luckowL Offline
              luckowL Offline
              luckow
              translator
              wrote on last edited by
              #5

              @nebulon Whoops

              Dec 03 16:12:40 - [Tue Dec 03 15:12:40.539273 2024] [php:error] [pid 24] [client 172.18.0.1:53960] PHP Fatal error: Uncaught CodeIgniter\\Exceptions\\ConfigException: You must set an array with Proxy IP address key and HTTP header name value in Config\\App::$proxyIPs. in /app/code/vendor/codeigniter4/framework/system/HTTP/RequestTrait.php:74\nStack trace:\n#0 /app/code/vendor/codeigniter4/framework/system/Config/Services.php(697): CodeIgniter\\HTTP\\Request->getIPAddress()\n#1 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(312): CodeIgniter\\Config\\Services::session()\n#2 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(251): CodeIgniter\\Config\\BaseService::__callStatic()\n#3 /app/code/vendor/codeigniter4/framework/system/Config/Services.php(668): CodeIgniter\\Config\\BaseService::getSharedInstance()\n#4 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(312): CodeIgniter\\Config\\Services::session()\n#5 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(202): CodeIgniter\\Config\\BaseService::__callStatic()\n#6 /app/code/vendor/codeigniter4/framework/system/Common.php(998): CodeIgniter\\Config\\BaseService::get()\n#7 /app/code/vendor/codeigniter4/framework/system/Common.php(971): service()\n#8 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(685): session()\n#9 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(703): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->getSessionUserInfo()\n#10 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(390): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->getSessionUserKey()\n#11 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(374): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->checkUserState()\n#12 /app/code/vendor/codeigniter4/shield/src/Auth.php(191): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->loggedIn()\n#13 /app/code/app/Views/errors/html/production.php(13): CodeIgniter\\Shield\\Auth->__call()\n#14 /app/code/vendor/codeigniter4/framework/system/Debug/BaseExceptionHandler.php(266): include('...')\n#15 /app/code/vendor/codeigniter4/framework/system/Debug/BaseExceptionHandler.php(269): CodeIgniter\\Debug\\BaseExceptionHandler->CodeIgniter\\Debug\\{closure}()\n#16 /app/code/vendor/codeigniter4/framework/system/Debug/ExceptionHandler.php(114): CodeIgniter\\Debug\\BaseExceptionHandler->render()\n#17 /app/code/vendor/codeigniter4/framework/system/Debug/Exceptions.php(163): CodeIgniter\\Debug\\ExceptionHandler->handle()\n#18 [internal function]: CodeIgniter\\Debug\\Exceptions->exceptionHandler()\n#19 {main}\n thrown in /app/code/vendor/codeigniter4/framework/system/HTTP/RequestTrait.php on line 74
              Dec 03 16:12:40 - [Tue Dec 03 15:12:40.539541 2024] [php:error] [pid 24] [client 172.18.0.1:53960] PHP Fatal error: Uncaught CodeIgniter\\Exceptions\\ConfigException: You must set an array with Proxy IP address key and HTTP header name value in Config\\App::$proxyIPs. in /app/code/vendor/codeigniter4/framework/system/HTTP/RequestTrait.php:74\nStack trace:\n#0 /app/code/vendor/codeigniter4/framework/system/Config/Services.php(697): CodeIgniter\\HTTP\\Request->getIPAddress()\n#1 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(312): CodeIgniter\\Config\\Services::session()\n#2 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(251): CodeIgniter\\Config\\BaseService::__callStatic()\n#3 /app/code/vendor/codeigniter4/framework/system/Config/Services.php(668): CodeIgniter\\Config\\BaseService::getSharedInstance()\n#4 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(312): CodeIgniter\\Config\\Services::session()\n#5 /app/code/vendor/codeigniter4/framework/system/Config/BaseService.php(202): CodeIgniter\\Config\\BaseService::__callStatic()\n#6 /app/code/vendor/codeigniter4/framework/system/Common.php(998): CodeIgniter\\Config\\BaseService::get()\n#7 /app/code/vendor/codeigniter4/framework/system/Common.php(971): service()\n#8 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(685): session()\n#9 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(703): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->getSessionUserInfo()\n#10 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(390): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->getSessionUserKey()\n#11 /app/code/vendor/codeigniter4/shield/src/Authentication/Authenticators/Session.php(374): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->checkUserState()\n#12 /app/code/vendor/codeigniter4/shield/src/Auth.php(191): CodeIgniter\\Shield\\Authentication\\Authenticators\\Session->loggedIn()\n#13 /app/code/app/Views/errors/html/production.php(13): CodeIgniter\\Shield\\Auth->__call()\n#14 /app/code/vendor/codeigniter4/framework/system/Debug/BaseExceptionHandler.php(266): include('...')\n#15 /app/code/vendor/codeigniter4/framework/system/Debug/BaseExceptionHandler.php(269): CodeIgniter\\Debug\\BaseExceptionHandler->CodeIgniter\\Debug\\{closure}()\n#16 /app/code/vendor/codeigniter4/framework/system/Debug/ExceptionHandler.php(114): CodeIgniter\\Debug\\BaseExceptionHandler->render()\n#17 /app/code/vendor/codeigniter4/framework/system/Debug/Exceptions.php(163): CodeIgniter\\Debug\\ExceptionHandler->handle()\n#18 /app/code/vendor/codeigniter4/framework/system/Debug/Exceptions.php(252): CodeIgniter\\Debug\\Exceptions->exceptionHandler()\n#19 [internal function]: CodeIgniter\\Debug\\Exceptions->shutdownHandler()\n#20 {main}\n thrown in /app/code/vendor/codeigniter4/framework/system/HTTP/RequestTrait.php on line 74
              

              Pronouns: he/him | Primary language: German

              1 Reply Last reply
              0
              • nebulonN nebulon

                @luckow where is that analytics page in the app? I can't seem to find that to test a fix.

                You could also put app.proxyIPs="172.18.0.1" into /app/data/env and restart the app to see if this fixes it

                luckowL Offline
                luckowL Offline
                luckow
                translator
                wrote on last edited by
                #6

                @nebulon You need to have one podcast.
                (admin) home -> podcasts -> all podcasts -> choose one
                podcast dashboard -> analytics -> locations

                1c4e237d-3179-4b7c-9179-e373bd4907e8-image.png

                Pronouns: he/him | Primary language: German

                1 Reply Last reply
                1
                • nebulonN Away
                  nebulonN Away
                  nebulon
                  Staff
                  wrote on last edited by
                  #7

                  right, found this now, thanks

                  1 Reply Last reply
                  1
                  • nebulonN Away
                    nebulonN Away
                    nebulon
                    Staff
                    wrote on last edited by
                    #8

                    So the fix is to add app.proxyIPs.0="172.18.0.0/16" to the env file, will be part of next package release.

                    luckowL 1 Reply Last reply
                    0
                    • nebulonN nebulon

                      So the fix is to add app.proxyIPs.0="172.18.0.0/16" to the env file, will be part of next package release.

                      luckowL Offline
                      luckowL Offline
                      luckow
                      translator
                      wrote on last edited by
                      #9

                      @nebulon nope.
                      You are right: with this addition the app starts instead of throwing php errors. But:
                      As soon as you click on a podcast link on the start page, you are redirected to https://localhost:8080/.
                      It feels like the magic sauce is missing.

                      Pronouns: he/him | Primary language: German

                      1 Reply Last reply
                      0
                      • nebulonN Away
                        nebulonN Away
                        nebulon
                        Staff
                        wrote on last edited by
                        #10

                        yes, you have add more newlines in the env file in the end. I have fixed the package so this isn't required with next version.

                        1 Reply Last reply
                        2
                        • jamesJ james has marked this topic as solved on

                        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