[Pkg-libvirt-commits] [libguestfs] 229/266: v2v: -o glance: Write potentially huge temporary images to /var/tmp by default.

Hilko Bengen bengen at moszumanska.debian.org
Fri Oct 3 14:42:07 UTC 2014


This is an automated email from the git hooks/post-receive script.

bengen pushed a commit to annotated tag debian/1%1.27.35-1
in repository libguestfs.

commit 510329939bf675a20f782939f8857ac433acec5c
Author: Richard W.M. Jones <rjones at redhat.com>
Date:   Sun Aug 31 14:09:51 2014 +0100

    v2v: -o glance: Write potentially huge temporary images to /var/tmp by default.
    
    Instead of /tmp.  This can be controlled by setting
    $LIBGUESTFS_CACHEDIR or $TMPDIR.
---
 v2v/output_glance.ml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/v2v/output_glance.ml b/v2v/output_glance.ml
index f04006d..f858f91 100644
--- a/v2v/output_glance.ml
+++ b/v2v/output_glance.ml
@@ -31,7 +31,8 @@ class output_glance verbose =
    * to write to a temporary file.  XXX
    *)
   let tmpdir =
-    let t = Mkdtemp.temp_dir "glance." "" in
+    let base_dir = (new Guestfs.guestfs ())#get_cachedir () in
+    let t = Mkdtemp.temp_dir ~base_dir "glance." "" in
     rmdir_on_exit t;
     t in
 object

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-libvirt/libguestfs.git



More information about the Pkg-libvirt-commits mailing list