Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove lockfile in home directory on startup #85

Open
bradjones1 opened this issue Oct 30, 2018 · 4 comments
Open

Remove lockfile in home directory on startup #85

bradjones1 opened this issue Oct 30, 2018 · 4 comments

Comments

@bradjones1
Copy link

When a pod is killed, Jira doesn't clean up its lock file in the home directory. Atlassian's own documentation (well, blog post) shows a bootstrap script that removes the existing lock file, if found. Should we do the same here?

@bradjones1
Copy link
Author

I'm accomplishing this with an init container for the moment, however it seems like this would be appropriate in the entrypoint script, as well.

@Alwandy
Copy link

Alwandy commented Dec 30, 2018

Same issue..., what I did is I created another script that tries to find .lock file and if found it deletes then runs the startup process. Sound similar to you @bradjones1 ?

@bradjones1
Copy link
Author

@Alwandy The official K8s way of doing this would be to use an init container to do what you just described, then run the application. It would be good to include that logic inside this image directly, but an init container allows you to run your setup tasks (like deleting the lock file) without having to build your own image just to add a line to the entrypoint script.

@Alwandy
Copy link

Alwandy commented Dec 31, 2018

@bradjones1 thanks, what I did is just do this for docker:
# Delete .lock before launching JIRA again (USING SED) RUN sed --in-place '1 a rm -f /var/atlassian/jira/.jira-home.lock;' /opt/atlassian/jira/bin/start-jira.sh

I hope this can be prioritised in any way...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants