When a docker container crashes and I make a new one, how can I ensure I have the settings from the last one in place? The container I am running contains Jenkins only.
Asked
Active
Viewed 243 times
1 Answers
0
You need to use a volume if you want your configuration changes to be persisted.
In the image I am using as a base (usually jenkins/jenkins:2.75-alpine), the configuration lives under: /var/jenkins_home/workspace
so all I need to do is something like:
docker run -v /path/on/host:/var/jenkins_home jenkins/jenkins:2.75-alpine
iocanel
- 492
- 2
- 2