Analytics - Location not applicable because of local ip
-
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?

-
N nebulon marked this topic as a question on
-
@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/envand restart the app to see if this fixes it@nebulon
WhoopsDec 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 -
@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/envand restart the app to see if this fixes it -
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.@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. -
J 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
