KB : Quick install Jira for test / troubleshooting
This is a script that I have created to quickly install any version of Jira that I might need to reproduce an issue. It’s bare-bones and can be improved, but I wanted to share as it can help some people.
It assumes that you have Java installed and the $JAVA_HOME
properly set. If you have not done that yet, you can follow the Installing Java documentation.
It also assumes that you have ~/deployments/downloads on your system. Create it before hand with: mkdir -p ~/deployments/downloads
Or modify the script if you wish. :)
Step 1
Download the script:
#!/bin/bash
version=$1
package="atlassian-jira-software"\-$version
download_jira () {
wget <https://www.atlassian.com/software/jira/downloads/binary/$package.zip>
}
cd ~/deployments/downloads
download_jira $version
cd ../
unzip downloads/$package.zip
mv $package"-standalone" "jira"$version
cd jira$version
mkdir jira-home
echo ---
echo "Please go into your new Jira installation and then you need to do something"
echo "like 'echo jira.home=/path/to/jira-home > atlassian-jira/WEB-INF/classes/jira-application.properties'"
echo "to set the Jira Home. Once you have done that, you can start it with 'bin/start-jira.sh'"
echo ---
I call it jira.sh
Step 2
Save it somewhere and if you want, you can set a path to be able to run from anywhere, or just at your downloads folder.
Step 3
Give permissions. You can do chmod +x jira.sh
Step 4
Use it. If you want Jira version 8.13.4, you run it like:./jira.sh 8.13.4
It will download, unzip, create a jira-home
directory and have it ready for you to set the jira-home
and start it.
Misc information
In the future, I plan to add more functionality such as setting the jira-home
automatically and some additional options to which paths to use. But for now, it suits my needs.
PS: I’m aware of Docker and sometimes I use. But when I quickly need a version of Jira, I find my script faster.