From cc7952c232a7cde766893befedd7d39e44111b1e Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Wed, 5 Oct 2022 17:38:16 -0400 Subject: [PATCH] Add additional import for config --- api-daemon/provisioner/examples/1-noinstall.py | 7 +++++++ api-daemon/provisioner/examples/2-debootstrap.py | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/api-daemon/provisioner/examples/1-noinstall.py b/api-daemon/provisioner/examples/1-noinstall.py index 7ab04271..bfe39c34 100644 --- a/api-daemon/provisioner/examples/1-noinstall.py +++ b/api-daemon/provisioner/examples/1-noinstall.py @@ -257,6 +257,9 @@ class VMBuilderScript(VMBuilder): # Run any imports first from pvcapid.vmbuilder import open_zk + from pvcapid.Daemon import config + import daemon_lib.common as pvc_common + import daemon_lib.ceph as pvc_ceph # First loop: Create the disks, either by cloning (pvc_ceph.clone_volume), or by # new creation (pvc_ceph.add_volume). @@ -397,6 +400,10 @@ class VMBuilderScript(VMBuilder): need cleanup before teardown of the overlay chroot environment. """ + # Run any imports first + import daemon_lib.common as pvc_common + import daemon_lib.ceph as pvc_ceph + temp_dir = "/tmp/target" for volume in list(reversed(self.vm_data["volumes"])): diff --git a/api-daemon/provisioner/examples/2-debootstrap.py b/api-daemon/provisioner/examples/2-debootstrap.py index e8d6ccc9..a1bef487 100644 --- a/api-daemon/provisioner/examples/2-debootstrap.py +++ b/api-daemon/provisioner/examples/2-debootstrap.py @@ -261,6 +261,9 @@ class VMBuilderScript(VMBuilder): # Run any imports first from pvcapid.vmbuilder import open_zk + from pvcapid.Daemon import config + import daemon_lib.common as pvc_common + import daemon_lib.ceph as pvc_ceph # First loop: Create the disks, either by cloning (pvc_ceph.clone_volume), or by # new creation (pvc_ceph.add_volume). @@ -580,6 +583,10 @@ GRUB_DISABLE_LINUX_UUID=false need cleanup before teardown of the overlay chroot environment. """ + # Run any imports first + import daemon_lib.common as pvc_common + import daemon_lib.ceph as pvc_ceph + temp_dir = "/tmp/target" for volume in list(reversed(self.vm_data["volumes"])):