Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Upgrade JIRA with Ansible?

It looks like you can do an unattended install of JIRA, but I don't see a method to do an unattended upgrade?

Specifically my Ansible role currently has to download the latest .bin installer...and quit. I then have to log manually into the server to run the upgrade, I would much prefer Ansible to complete the upgrade on its own without my human fallibility!

6 answers

2 accepted

1 vote
Answer accepted
Thomas Deiler Community Leader Feb 01, 2018

Dear @jmo,

I totally understand your needs. I was same once in the situation to make upgrades more comfortable. So I did this with several RPMs.

It work somehow little bit better, but not unattended. In the end I stopped it.

My recommendation is not to do this with Ansible or any other tool, if data integrity is very important for you (several hundred serious users). There are so many pitfalls, that can make your life harder than upgrading manually. To name some:

  • plugins, that need to be installed via UPM and not just copied inside the plugin directory
  • dependencies to Jira (other linked Apps) that are not notified
  • extra installation steps for specific versions
  • config files that change, where patches cannot be applied

So long


Thomas Deiler Community Leader Feb 05, 2018

Dear @jmo,

was my answer fine enough to be also "accepted"?

Many Thanks


Yes thanks for this detailed answer Thomas, I'm glad someone has at least tried to work around Atlassian's limitations. Basically the headaches to upgrading manually (updating multiple config files in multiple places, for ex) pale in comparison to the headaches for trying to upgrade automatically.

0 votes
Answer accepted

Ultimately it looks like this is a shortcoming of JIRA, and an example of the incongruities of how apps in the Atlassian suite are installed/updated/maintained. For example Bamboo, Confluence, Crowd and more can have their installations/updates automated, but not JIRA. It would be nice if all the apps in the suite were designed by be administered the same way.

Thomas Deiler Community Leader Feb 05, 2018

Very true. Probably once Atlassian will pick up your suggestion and realize it. Who knows ...

Why should this not be possible for JIRA? I am running all updates via ansible. For example: 

# Create response.varfile from for unattended installation
- name: Create response.varfile
path: /{{ app_path }}/response.varfile
state: touch
mode: 0755
- name: Fill response.varfile
path: /{{app_path}}/response.varfile
line: "{{ item.line }}"
state: present
create: yes
- { line: 'backupJira$Boolean=true' }
- { line: 'app.install.service$Boolean=false' }
- { line: 'existingInstallationDir=/{{ app_path }}/{{ app }}' }
- { line: 'app.jiraHome=/data/{{ app }}' }
- { line: 'sys.confirmedUpdateInstallationString=true' }
- { line: 'sys.languageId=en' }
- { line: 'sys.installationDir=/{{ app_path }}/{{ app }}' }
- { line: 'executeLauncherAction$Boolean=true' }
- { line: 'httpPort$Long=8080' }
- { line: 'portChoice=custom' }

After that you can run the .bin file: 

 - name: Run Upgrade 
command: /{{ app_path }}/atlassian-jira-software-{{jira_version}}-x64.bin -q -varfile /{{app_path}}/response.varfile


Worked fine for me. 

Do you have a repo for this role I am curious to see the source code.

Hi @Dithmar Reutlinger , Your suggestion worked like a charm. Can you please let me know how you got the parameters for the response file? It will be helpful for me to do the same for Confluence and Bitbucket.




Hi @Charles Mervin ,

Here is an example for Confluence: 

- { 
line'executeLauncherAction$Boolean=true' }      
- { 
line'app.confluenceHome=/data/{{ app}}' }      
- { 
line'sys.confirmedUpdateInstallationString=true' }     
- { 
line'launch.application$Boolean=false' }      
- { 
line'existingInstallationDir=/app/{{ app }}' }      
- { 
line'sys.languageId=en' }      
- { 
line'sys.installationDir=/app/{{ app }}' }     
- { 
line'backupConfluence$Boolean=false' }


I am not running Bitbucket so I am not able to support here. 

Regards, Dithmar

Hi @Dithmar Reutlinger ,

Many thanks, this helped with my Confluence upgrade. 



Hello @Dithmar Reutlinger ,

I am getting the below error while executing the ansible play book but notable to understood which directory I have missed,

"invocation": {
    "module_args": {
         "_raw_params": "/tmp/atlassian-jira-software-8.1.0-x64.bin -q -varfile                /tmp/response.varfile",
         "_uses_shell": false,
         "argv": null,
         "chdir": null,
         "creates": null,
         "executable": null,
         "removes": null,
         "stdin": null,
         "stdin_add_newline": true,
         "strip_empty_ends": true,
         "warn": true
"msg": "non-zero return code",
"rc": 1,
"start": "2020-12-08 14:30:45.984883",
"stderr": "No directory found in specified location",
"stderr_lines": [
      "No directory found in specified location"
"stdout": "Unpacking JRE ...\nStarting Installer ...",
"stdout_lines": [
       "Unpacking JRE ...",
       "Starting Installer ..."

Hello @Dithmar Reutlinger @Dithmar Reutlinger 

Application upgrade is happening in test env perfectly with fewer data. But I am facing a problem in production with back up the JIRA_HOME directory. Due to huge data and attachments, it is taking lots of time. While doing manually we are skipping to back up the JIRA home directory. 

Please let us know how we can skip the JIRA_HOME directory (/var/Atlassian/..) in the upgrade process through the Ansible playbook.

Are there any repos that I can take a look to start with ?

I kinda finished it and we are live as well. I will publish it soon

Hi @Sid 

Do you have a chance to publish it already ?




Our team has started to automate Jira with Ansible when installer does not exist yet.

So our playbook operates a similar way for most Atlassian products:

- prepare database

- download zip package

- extract it at /opt/atlassian/ and creates a shortcut link as /opt/atlassian/jira

- create service account and configure systemd service

- prepare JIRA_HOME location at /var/atlassian/application-data/jira/

- apply configuration: dbconfig.xml,, custom release notes templates, sso support...

- download and apply patches from Jira Field Security, for instance

Some manual steps remains for an effective installation but almost complete an upgrade process. What may be really useful from Ansible too:

- Apps management in UPM but this may help: at least to bootstrap and get JCLI available:

- Update license if renewed since last playbook execution

- Trigger full reindex if put off to upgrade faster

- Integrity checks execution

- Report health check status

If fact, I cannot compare this Ansible playbook usage with Atlassian installer as I have never used it.

Suggest an answer

Log in or Sign up to answer

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you