Mico
Mico

Reputation: 413

TeamCity configuration doesn't persist inside docker

I've setup TeamCity inside a docker image and I can access it via localhost but everytime I restart my docker, TeamCity always ask for configuration again (from the beginning, meaning that I have to reconfigure the whole TeamCity again).

How do I make my configuration persist?

Upvotes: 1

Views: 609

Answers (1)

VonC
VonC

Reputation: 1324248

How do I make my configuration persist?

You can mount a volume or use a data volume container, in order to persist that configuration.

If you do not, the copy-on-write mechanism used by docker would remove any modification of docker rm (unless you docker commit right after a docker stop)

For example, this Teamcity docker project runs it with a mounted volume:

docker run --link some-postgres:postgres \
  -v <teamcitydir>:/var/lib/teamcity -d \
  sjoerdmulder/teamcity:latest

Upvotes: 2

Related Questions