- 
                Notifications
    
You must be signed in to change notification settings  - Fork 557
 
Open
Description
I have a NextJS 14 app hosted on Apache using Passenger.
When a route (other than the root path) is refreshed via code with router.refresh() or refreshed manually in the browser, the server throws a generic 500 Internal Server Error:

The log file shows:
[Mon Jun 02 14:45:47.545905 2025] [core:error] [pid 1153606:tid 1153663] [remote IP] AH00124: Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace., referer: https://domain.com/path?type=open
Conf override generated by Passenger in WHM (via cPanel Application Manager):
#  /etc/apache2/conf.d/userdata/ssl/2_4/user/domain.com/account.conf
<Location "/">
    <IfModule mod_env.c>
        SetEnv "APP_VERSION" "0.1-alpha"
    </IfModule>
    <IfModule mod_passenger.c>
        PassengerAppEnv "production"
        PassengerEnabled on
        PassengerBaseURI "/"
        PassengerAppRoot "/home/user/public_html/domains/path"
        PassengerAppGroupName "user - account def"
        PassengerRuby /usr/bin/ruby
        PassengerPython /usr/bin/python-html2text
        PassengerNodejs /opt/cpanel/ea-nodejs20/bin/node
    </IfModule>
</Location>
<Directory "/home/user/public_html/domains/path">
    Allow from all
    Options -MultiViews
    Options -Indexes
    Require all granted
</Directory>
Server Info:
AlmaLinux v9.6.0
Apache 2.4
Passenger Version: 6.0.27
Node v20.19.2
Any guidance much appreciated.
Metadata
Metadata
Assignees
Labels
No labels