Hello JIRA specialist,
An issue on my site about the reverse proxy configuration.
I can reach my website and connect to JIRA since each station. But when I click on a link (as Task or Adminstration page, ...), the system try to connect to localhost:8080
What kind of things I've make wrong?
server.xml:
<Connector port="8080" maxThreads="150" minSpareThreads="25" connectionTimeout="20000" enableLookups="false" maxHttpHeaderSize="8192" protocol="HTTP/1.1" useBodyEncodingForURI="true" redirectPort="8443" acceptCount="100" disableUploadTimeout="true" bindOnInit="false" scheme="https" proxyName="jira.mywebsite.ch" proxyPort="443"/>
nginx.conf
# SSL configuration for JIRA
server {
listen 443 ssl;
server_name jira.mywebsite.ch;
# certs sent to the client in SERVER HELLO are concatenated in ssl_certificate
ssl on;
error_page 497 https://$host$request_uri;
ssl_certificate C:\Admin\certs\certificate.crt;
ssl_certificate_key C:\Admin\certs\private.key;
ssl_session_timeout 1d;
ssl_session_cache shared:SSL:50m;
ssl_session_tickets off;
# modern configuration. tweak to your needs.
ssl_protocols TLSv1.2;
ssl_ciphers '...';
ssl_prefer_server_ciphers on;
# HSTS (ngx_http_headers_module is required) (15768000 seconds = 6 months)
add_header Strict-Transport-Security max-age=15768000;
#ssl_stapling on;
#ssl_stapling_verify on;
# Optional optimisation - please refer to http://nginx.org/en/docs/http/configuring_https_servers.html
# ssl_session_cache shared:SSL:10m;
location / {
proxy_buffers 8 24k;
proxy_buffer_size 2k;
proxy_pass http://localhost:8080/;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Real-IP $remote_addr;
proxy_read_timeout 1200;
proxy_redirect off;
}
Hello @Damien Frutiger,
it seems like you might have not set properly the Base URL in your Jira instance, can you check this how-to to make sure everythiing is set up properly ?
Also, I'm not an Nginx expert but it seems that your ProxyPass should be pointing to your Jira instance and not localhost.
Let me know if this helps,
--Alexis
sorry for the late answer but I'm not working in this subject until today.
I've checked that you said again and all is good for me.
Have you another idea?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Damien Frutiger,
what if you change the
proxy_pass http://localhost:8080/;
from localhost to the server IP where Jira is located ?
Also, on Apache I usually have a "ProxyPassReverse" line in the host config (set to the same value as ProxyPass), maybe there's a similar config for Nginx ?
--Alexis
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.