When running Redmine (such as with the Redmine People plugin) behind an Nginx reverse proxy, user profile links, generated URLs, or buttons may incorrectly point to the backend local IP address and port (e.g., http://10.1.0.41:8080/people/...) instead of your configured public domain. This typically happens because Nginx is not passing the original host and request protocol headers to the backend Redmine application.
To resolve this, you need to update your Nginx configuration block to pass the correct proxy headers so Redmine knows the actual domain and protocol requested by the client.
- Locate your Nginx configuration file
- Update the location block with proxy headers
- Test and reload Nginx
- Verification
Locate your Nginx configuration file
Note: Requires root or sudo access.
Open your site's Nginx server block configuration file (commonly located in /etc/nginx/sites-available/ or /etc/nginx/conf.d/).
Verification: You can view the file using a text editor like sudo nano /etc/nginx/sites-available/your_redmine.
Update the location block with proxy headers
Note: Required step.
Inside your location / block pointing to your Redmine backend, ensure that all required proxy headers (Host, X-Forwarded-Proto, X-Forwarded-Host, etc.) are explicitly defined.
Update your configuration to match the example below:
Nginx
location / {
proxy_pass http://10.1.0.41:8080/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Port $server_port;
}
Verification: Check that all six proxy_set_header lines are present inside the block.
Test and reload Nginx
2 min
Save the configuration file, test the Nginx configuration for syntax errors, and reload the service:
Bash
sudo nginx -t sudo systemctl reload nginx
Verification: The nginx -t command returns a success message confirming the configuration is syntactically valid.
Verification
Once Nginx has been reloaded, navigate to your public Redmine domain, check a user profile page or generated link within the People plugin, and confirm that URLs now properly reflect your public domain name instead of the internal backend IP and port.