This question is in reference to Atlassian Documentation: Integrating JIRA with Nginx
I set up the Nginx proxy as described here.
When I go to JIRA, anything at <base url>/s/ seems not to load. Most of the application's assets like CSS, JS and images seem to be found at this path.
Accessing JIRA directly, bypassing the proxy, works fine.
If I follow the URL of the assets (for example using the Networks tab of Chrome's debugging tools), I see a JIRA 404 page, rather than nginx.
My configurations:
<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" proxyName="<domain>" proxyPort="80"/>
server { listen <domain>:80; server_name <domain>; location /jira { 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_pass http://localhost:8080/jira/; client_max_body_size 10M; } }
Where <domain> is the domain at which I wish to access JIRA
I checked out my access logs for JIRA, located at /opt/atlassian/jira/logs/ which showed me requests similar to "GET /jira//s/d41d8cd98f00b204e9800998ecf8427e-CDN/[...]" - there is an extra slash by /jira//
So double-checking my nginx and JIRA config shows the only trailing slash - in the nginx config.
Changing proxy_pass http://localhost:8080/jira/ to proxy_pass http://localhost:8080/jira fixed it for me.
Whoo! Thanks for providing your solution! I've definitely done that before myself. >_<
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yeah, I think I had found some results that were similar but not exactly like my resolution. In particular, there is an Atlassian documentation that specifies how to fix that extra slash on the JIRA Tomcat server, but not if it's coming from nginx. Anyway, thought it might be useful!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I had this issue as well, but checking the configuration file I forgot to comment the followind lines:
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# include snippets/fastcgi-php.conf;
#
# # With php7.0-cgi alone:
# fastcgi_pass 127.0.0.1:9000;
# # With php7.0-fpm:
# fastcgi_pass unix:/run/php/php7.0-fpm.sock;
#}
and
#location = /favicon.ico { log_not_found off; access_log off; }
#location = /robots.txt { log_not_found off; access_log off; allow all; }
#location ~* \.(css|gif|ico|jpeg|jpg|js|png)$ {
# expires max;
# log_not_found off;
#}
After that it stared to work
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For me changing the proxy_pass directive did not solve the issue.
Here's my nginx.conf
location /jira {
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_pass http://192.168.0.110:8081/jira;
client_max_body_size 10M;
}
and the error I get when accessing: http://192.168.0.110/jira/secure/Dashboard.jspa
not found.
However, I think it's a nginx config issue, but I don't manage to solve it.
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.
Can you share your configuration details?
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.