摘要: 配置nginx反向代理jira并实现https 配置Tomcat 在本文中,我们设置可以在地址http://jira.aniu.so/jira(标准HTTP端口80)上访问JIRA,而JIRA本身可以使用上下文路径/ jira监听端口8080。
更改前: <Context docBase="${catalina.home}/atlassian-jira" path="" reloadable="false" useHttpOnly="true"> 更改后: <Context docBase="${catalina.home}/atlassian-jira" path="/jira" reloadable="false" useHttpOnly="true">
<!-- Nginx Proxy Connector --> # 仅仅使用nginx不使用https <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="jira.aniu.so" proxyPort="80"/> <!-- OPTIONAL,Nginx Proxy Connector with https --> # 本文使用这次方式 <Connector port="8081" maxThreads="150" minSpareThreads="25" connectionTimeout="20000" enableLookups="false" maxHttpHeaderSize="8192" protocol="HTTP/1.1" useBodyEncodingForURI="true" redirectPort="8443" acceptCount="100" disableUploadTimeout="true" proxyName="jira.aniu.so" proxyPort="443" scheme="https" secure="true"/> <!-- Standard HTTP Connector --> <Connector port="8082" maxThreads="150" minSpareThreads="25" connectionTimeout="20000" enableLookups="false" maxHttpHeaderSize="8192" protocol="HTTP/1.1" useBodyEncodingForURI="true" redirectPort="8443" acceptCount="100" disableUploadTimeout="true"/>
上面注释是原有的,下面是自己修改的
配置nginx的虚拟主机:
在之后重启nginx 和jira就可以起了
系统面板就正常显示了: