Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Jira docker container recreates dbconfig.xml when restarting container

joshysav August 20, 2019

Hi peoples,

Running Jira in a docker container that is accessible using a proxy server (nginx). I've modified the dbconfig.xml to route using the proxy. 

But it seems that the dbconfig.xml is rewritten by init, each time I restart the container.

 

Hope this is enough information.

 

 

2 answers

1 accepted

0 votes
Answer accepted
Johann Kiefel
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 21, 2019

yes, we have the same problem

we use the official docker image : atlassian/jira

After initial setup, everything works fine.

If we stop the container and start it again, the setting in dbconfig.xml get lost. We have todo the setup again. Of cource it doesn't work, because the DB is not empty anymore.

How can we prevent that dbconfig.xml is replaced through an empty template during the start of jira docker container.

Chris G.
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 21, 2019 edited

You are right. The entrypoint.py:L54-65 overwrites server.xml, dbconfig.xml and so on.

So basically commenting L54 to L65 should stop the overwrites.

I would create a bug report but i can't find the repository.

joshysav August 22, 2019

Thank you very much Johann and Chris for taking the time to answer! 

I'm not able to find the location to report this bug (feature). In the meantime I have commented out L54 to L65, then commited atlassian/jira to a new docker image.

To create a new image based on the changes.

# login to jira container
docker exec -it jira bash 

# install editor on jira container

apt update
apt install vim

# modify entrypoint.sh
cd /
vim entrypoint.sh

# comment out lines L54 to L65

# save and exit vim
:wq

# logout of jira container
exit

# stop jira
docker stop jira

# copy jira to new image

git commit jira custom/my-new-jira

# remove old jira container
docker rm jira

then install and run /custom/my-new-jira container
 

 

Hope this might be of help to someone in the future.

 

Thanks again!

0 votes
Chris G.
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 22, 2019 edited

Looking at tag 8.3.2 the issue should be fixed.

There is now an "overwrite" parameter which is set to "false" for dbconfig.xml and hence only creates the file from the template if it doesn't exist.

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events