====== Настройка nginx для работы Jira ======
===== Jira прокси =====
В файле ''$JIRA_INSTALL/conf/server.xml'' нужно установить
* proxyName
* proxyPort
* scheme
* secure
Для работы с MySQL нужно скопировать драйвер в ''$JIRA_INSTALL/lib''
* [[https://confluence.atlassian.com/adminjiraserver/connecting-jira-applications-to-mysql-938846854.html|Connecting Jira applications to MySQL 5.6]]
* [[https://confluence.atlassian.com/adminjiraserver072/connecting-jira-applications-to-mysql-828787562.html|Connecting JIRA applications to MySQL]]
===== Конфиг для nginx =====
upstream jira {
server 127.0.0.1:8081 fail_timeout=0;
}
# listen on HTTP2/SSL
server {
listen 443 ssl http2;
server_name jira.domain.com;
ssl_certificate /etc/letsencrypt/live/jira.domain.com/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/jira.domain.com/privkey.pem;
location / {
client_max_body_size 10m;
proxy_set_header Host $host:$server_port;
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;
# hand the request off to jira on non-ssl
proxy_pass http://jira;
}
}
server {
listen 80;
server_name jira.domain.com;
root /opt/atlassian/jira;
location ~ /.well-known {
allow all;
}
location / {
return 302 https://jira.domain.com;
}
}
===== Установка Jira =====
--> Установка Jira#
$ wget https://product-downloads.atlassian.com/software/jira/downloads/atlassian-jira-software-8.0.0-x64.bin
$ chmod a+x atlassian-jira-software-8.0.0-x64.bin
$ sudo ./atlassian-jira-software-8.0.0-x64.bin
Unpacking JRE ...
Starting Installer ...
Feb 13, 2019 6:45:47 PM java.util.prefs.FileSystemPreferences$1 run
INFO: Created user preferences directory.
Feb 13, 2019 6:45:47 PM java.util.prefs.FileSystemPreferences$2 run
INFO: Created system preferences directory in java.home.
This will install JIRA Software 8.0.0 on your computer.
OK [o, Enter], Cancel [c]
Choose the appropriate installation or upgrade option.
Please choose one of the following:
Express Install (use default settings) [1], Custom Install (recommended for advanced users) [2, Enter], Upgrade an existing JIRA installation [3]
Where should JIRA Software be installed?
[/opt/atlassian/jira]
Default location for JIRA Software data
[/var/atlassian/application-data/jira]
Configure which ports JIRA Software will use.
JIRA requires two TCP ports that are not being used by any other
applications on this machine. The HTTP port is where you will access JIRA
through your browser. The Control port is used to startup and shutdown JIRA.
Use default ports (HTTP: 8080, Control: 8005) - Recommended [1, Enter], Set custom value for HTTP and Control ports [2]
JIRA can be run in the background.
You may choose to run JIRA as a service, which means it will start
automatically whenever the computer restarts.
Install JIRA as Service?
Yes [y, Enter], No [n]
Details on where JIRA Software will be installed and the settings that will be used.
Installation Directory: /opt/atlassian/jira
Home Directory: /var/atlassian/application-data/jira
HTTP Port: 8080
RMI Port: 8005
Install as service: Yes
Install [i, Enter], Exit [e]
Extracting files ...
Please wait a few moments while JIRA Software is configured.
Installation of JIRA Software 8.0.0 is complete
Start JIRA Software 8.0.0 now?
Yes [y, Enter], No [n]
Please wait a few moments while JIRA Software starts up.
Launching JIRA Software ...
Installation of JIRA Software 8.0.0 is complete
Your installation of JIRA Software 8.0.0 is now ready and can be accessed
via your browser.
JIRA Software 8.0.0 can be accessed at http://localhost:8080
Finishing installation ...
<--
===== Ссылки =====
* [[https://confluence.atlassian.com/adminjiraserver/installing-jira-applications-on-linux-938846841.html|Installing Jira applications on Linux]]
* [[https://confluence.atlassian.com/adminjiraserver/running-the-setup-wizard-938846872.html|Running the setup wizard]]
* [[https://confluence.atlassian.com/jirakb/integrating-jira-with-nginx-426115340.html|Integrating JIRA with Nginx]]
* [[http://wiki.jtalks.org/pages/viewpage.action?pageId=5242888|Базовые знания (JIRA)]]
* [[http://wiki.jtalks.org/pages/viewpage.action?pageId=5242885|Рабочий цикл (JIRA)]]
{{tag>nginx mysql jira}}