-
-
Save ipeacocks/6d1d42e293954dac9a977ee089a8b181 to your computer and use it in GitHub Desktop.
Atlassian JIRA behind nginx + SSL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# force HTTP to HTTPS - /etc/nginx/conf.d/nonssl.conf | |
server { | |
listen 80; | |
server_name jira.example.com; | |
access_log off; | |
return 301 https://$server_name$request_uri; | |
} | |
# /etc/nginx/conf.d/jira.conf | |
server { | |
listen 443 default ssl; | |
server_name jira.example.com; | |
access_log off; | |
ssl on; | |
ssl_certificate /etc/nginx/certs/example.com.crt; | |
ssl_certificate_key /etc/nginx/certs/example.com.key; | |
# Set maximum body size to JIRA's maximum attachment size (10M by default) | |
client_max_body_size 10M; | |
location / { | |
proxy_set_header Host $host; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-Proto https; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
proxy_pass http://127.0.0.1:8080/; | |
} | |
} | |
# server.xml config file from $JIRA/conf/ | |
# add/modify this line from <Service name="Catalina"> directive | |
<Connector | |
acceptCount="100" | |
connectionTimeout="20000" | |
disableUploadTimeout="true" | |
enableLookups="false" | |
maxHttpHeaderSize="8192" | |
maxThreads="150" | |
minSpareThreads="25" | |
port="8080" | |
protocol="HTTP/1.1" | |
redirectPort="8443" | |
useBodyEncodingForURI="true" | |
scheme="https" | |
proxyName="jira.example.com" | |
proxyPort="443"/> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Possible useful links.
Jira setup:
https://confluence.atlassian.com/adminjiraserver071/installing-jira-applications-on-linux-802592173.html
Rerun setup:
https://confluence.atlassian.com/confkb/how-to-restart-the-setup-wizard-after-installing-confluence-179443224.html
Setup reverse proxy:
https://www.justinsilver.com/technology/atlassian-jira-nginx-ssl-reverse-proxy/
https://coder1.com/articles/proxy-jira-7-over-https-nginx
https://blog.servicerocket.com/adoption/blog/2014/07/3-steps-in-set-up-nginx-as-proxy-server-for-atlassian-jira
https://community.atlassian.com/t5/Jira-questions/Jira-behind-nginx-HTTPS-proxy-default-page/qaq-p/32107
https://confluence.atlassian.com/jirakb/integrating-jira-with-nginx-426115340.html
MySQL
https://confluence.atlassian.com/adminjiraserver/connecting-jira-applications-to-mysql-938846854.html
https://www.digitalocean.com/community/tutorials/how-to-install-mysql-on-ubuntu-16-04
Problem with self-signed cert:
https://confluence.atlassian.com/jirakb/gadgets-don-t-display-correctly-when-using-ssl-and-proxy-server-213520306.html