diff options
author | Matthew Heon <matthew.heon@pm.me> | 2019-02-21 09:42:22 -0500 |
---|---|---|
committer | Matthew Heon <matthew.heon@pm.me> | 2019-02-26 09:37:00 -0500 |
commit | d41d8d090e330fe2f0a3c75d24c409d9c345f841 (patch) | |
tree | af3c98f4ff6b6874202990e13131a4dbc9566950 /libpod/boltdb_state.go | |
parent | da70c9db6fb92c69d722d51873840c4e54dbe86d (diff) | |
download | podman-d41d8d090e330fe2f0a3c75d24c409d9c345f841.tar.gz podman-d41d8d090e330fe2f0a3c75d24c409d9c345f841.tar.bz2 podman-d41d8d090e330fe2f0a3c75d24c409d9c345f841.zip |
Validate VolumePath against DB configuration
If this doesn't match, we end up not being able to access named
volumes mounted into containers, which is bad. Use the same
validation that we use for other critical paths to ensure this
one also matches.
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Diffstat (limited to 'libpod/boltdb_state.go')
-rw-r--r-- | libpod/boltdb_state.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libpod/boltdb_state.go b/libpod/boltdb_state.go index 25ef5cd0e..c226a0617 100644 --- a/libpod/boltdb_state.go +++ b/libpod/boltdb_state.go @@ -261,12 +261,14 @@ func (s *BoltState) GetDBConfig() (*DBConfig, error) { storageRoot := configBucket.Get(graphRootKey) storageTmp := configBucket.Get(runRootKey) graphDriver := configBucket.Get(graphDriverKey) + volumePath := configBucket.Get(volPathKey) cfg.LibpodRoot = string(libpodRoot) cfg.LibpodTmp = string(libpodTmp) cfg.StorageRoot = string(storageRoot) cfg.StorageTmp = string(storageTmp) cfg.GraphDriver = string(graphDriver) + cfg.VolumePath = string(volumePath) return nil }) |