RT5 Login redirects to proxy pass adress localhost:3000

Hello. I am trying to setup RT5 on my debian 11 web server with apache and certbot. I am very new to this but basically, RT shows up when I go to my server url. If I enter wrong login it tells me that I entered wrong login, but if I enter correct root and password, I get redirected to proxypass adress that is localhost:3000 in my browser (Which is of course empty as I am not running the server on the same device). The login goes through though, if I again type the home URL of my server in to the browser, I am logged in. Any ideas on what to look for on how to fix this unpleasant redirect?

What configs do you have set for web domain/URL values in RT?

Hello. Thanks for your reply!

I fiddled around with more settings but did not get any results.
As of now I have

WebDomain set to the IP address of my server which was supposed to help me with CSF eliminating screen but did not. Before I had the domain name, no trailing slash, no port - same results

With WebPort I tried empty and also port 5000 which I am using in the rt socket config.

WebPath is empty

After posting this question I also tried adding WebBase URL as mydomain.com:443

Adding also some of my Apache site config:


 
        DocumentRoot /var/www/html
        RedirectMatch \^/\$ /opt/rt5/
        RewriteEngine on
        RewriteCond %{HTTP_HOST} ^146\.102\.54\.141$ 
        RewriteRule ^ - [F,L]

Header always set Strict-Transport-Security "max-age=31536000"
SSLUseStapling on
        Protocols h2 http/1.1

        ProxyFCGISetEnvIf true SCRIPT_NAME ""
        ProxyPass / http://localhost:3000/
        ProxyRequests     On

As of Apache config, I have tried rewriting proxypass to my actual domain:3000, which did not work, tried fiddling around with most of things like other mentioned proxy settings.

Not sure if it is important here, but I should mention, as shown higher, I use HSTS, which is a must for me.
I was thinking whether that could play a role but I don’t know.

SOLVED:

I solved my problem by adding ProxyPassReverse directive after my ProxyPass in my apache site config, like so:

ProxyPass / localhost:8080
ProxyPassReverse / localhost:8080

Hopefully this might help someone.