Keep existing data for containerized MongoDB
authorJiri Stransky <jistr@redhat.com>
Tue, 7 Mar 2017 13:22:33 +0000 (14:22 +0100)
committerJiri Stransky <jistr@redhat.com>
Tue, 14 Mar 2017 13:53:06 +0000 (13:53 +0000)
commit3c51cad7c99de162fd9ab06f975b637892247c94
tree4db21386368ecfd6840618304264028249b8a4c5
parentcd88f4d8e928daf0676a4a9b6f36d93df7a6aa7c
Keep existing data for containerized MongoDB

We used named Docker volume for MongoDB storage, which meant that when
moving from bare metal to containerized, we lost data and reinitialized
the storage from scratch.

With this commit we keep the data by mounting the original data into the
container. We also need make sure that file ownership is correct
according to the uid/gid used within MongoDB container image.

Change-Id: I86ef2cb37a068b767462d6d50fe451389b7cbb58
docker/services/database/mongodb.yaml