[lxc-devel] [lxd/master] lxd/patches: Updates patchStorageApiRenameContainerSnapshotsDir
tomponline on Github
lxc-bot at linuxcontainers.org
Wed Feb 26 22:11:57 UTC 2020
A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 390 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20200226/1ce0b8a5/attachment.bin>
-------------- next part --------------
From 0d6a42483b809abf4fba28d9a1d0a355fb06a6f3 Mon Sep 17 00:00:00 2001
From: Thomas Parrott <thomas.parrott at canonical.com>
Date: Wed, 26 Feb 2020 22:10:05 +0000
Subject: [PATCH] lxd/patches: Updates
patchStorageApiRenameContainerSnapshotsDir to use new storage driver
Signed-off-by: Thomas Parrott <thomas.parrott at canonical.com>
---
lxd/patches.go | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/lxd/patches.go b/lxd/patches.go
index 62a0de238b..80dbe4ae4d 100644
--- a/lxd/patches.go
+++ b/lxd/patches.go
@@ -3225,18 +3225,18 @@ func patchStorageApiRenameContainerSnapshotsDir(name string, d *Daemon) error {
// Iterate through all configured pools
for _, poolName := range pools {
// Make sure the pool is mounted
- pool, err := storagePoolInit(d.State(), poolName)
+ pool, err := storagePools.GetPoolByName(d.State(), poolName)
if err != nil {
return err
}
- ourMount, err := pool.StoragePoolMount()
+ ourMount, err := pool.Mount()
if err != nil {
return err
}
if ourMount {
- defer pool.StoragePoolUmount()
+ defer pool.Unmount()
}
// Figure out source/target path
More information about the lxc-devel
mailing list