docker
19.03+,docker-compose
1.27+
You have 3 choices with 3 different kinds of deployment.
-
With local deployment (HTTP only), we need to add
127.0.0.1 jira.internal
into hosts file:echo '127.0.0.1 jira.internal' | sudo tee -a /etc/hosts
-
With other deployment that requires SSL, simply change docker-compose files by referring
.env
:COMPOSE_FILE=docker-compose.yml:docker-compose.ssl.yml
Add your cert stuff into
certs/
, with full chain asfullchain1.pem
, trusted chain aschain1.pem
and private key asprivkey1.pem
. -
For Let's Encrypt SSL certificate auto-renewal, update your
.env
like below:COMPOSE_FILE=docker-compose.yml:docker-compose.acme.yml DOMAIN_NAME=jira.your-domain.com ACCOUNT_EMAIL[email protected]
Your SSL cert will be renewed automatically every 60 days, and configured with
OCSP Must Staple
andCertificate Transparency
.Moreover, your proxy will be enabled
TLS 1.3
,OCSP Stapling
,Forward Secrecy
andHSTS
.
-
Build them up:
In case of LE cert auto-renewal, you need to start
nginx-proxy
andnginx-proxy-acme
first:docker-compose up -d nginx-proxy-acme && docker-compose logs -f nginx-proxy nginx-proxy-acme
Then start the other containers with:
docker-compose up -d && docker-compose logs -f
If you don't need cert auto-renewal, only need to run the latter command.
-
Everything will be automatically configured, until you reach the license prompt screen:
-
Copy the license server id, for example
BPOD-YXDV-LMVB-DIC0
, then run command below, with-p
for product,-m
for email,-n
for license name,-s
for license server id:java -jar atlassian-agent.jar \ -p jira \ -m [email protected] \ -n hino \ -o akatsuki \ -s BPOD-YXDV-LMVB-DIC0
If
java
is not installed at your machine, use below docker command:docker run --rm -v "${PWD}/atlassian-agent.jar:/atlassian-agent.jar" \ openjdk:8-jre-alpine \ java -jar atlassian-agent.jar \ -p jira -m [email protected] -n hino -o akatsuki \ -s BPOD-YXDV-LMVB-DIC0
-
Copy the generated license code, get back to your browser and submit it, then BOOM!!! you're done 🐳
-
Check what they are doing behind your back:
docker-compose logs -f --tail 69
-
Tired of Jira, burn them down, but keep the volumes in case you change your mind:
docker-compose down
-
Be aware that changing postgres default database name (
postgres
->jira
), it'll create a new databasejira
and doesn't accept incoming connection during that time. Therefore you may encouter a problem when Jira perform DB pre-database startup check and can not start Jira server. You may need to:- Simply restart jira service with:
docker-compose restart jira
- Change postgres config
POSTGRES_DB
andPOSTGRES_USER
back to default aspostgres
- Implement docker delayed startup config, pls refer: https://docs.docker.com/compose/startup-order/
For the sake of simplicity, and meaningful DB config, I wont re-config it now, but will track and update if needed.
- Simply restart jira service with:
-
Change attachment size
Access this url:
https://<your-jira>/secure/admin/ViewAttachmentSettings.jspa
Change the
Attachment Size
to what you want (e.g. 20mb ~ 20971520b - note thatmb
here is actuallymib
), then updatenginx-proxy/proxy-wide.conf
correspondingly:client_max_body_size 20m;
Recreate your
nginx-proxy
container:docker-compose up -d --no-deps --force-recreate nginx-proxy
-
Last but not least, the Jira crack mechanism is thank to Zhile, you can refer the source and donate to him via: https://gitee.com/pengzhile/atlassian-agent