guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/02: gnu: docker: Use disjunct temp directories for probing.


From: guix-commits
Subject: 02/02: gnu: docker: Use disjunct temp directories for probing.
Date: Tue, 26 Mar 2019 07:23:45 -0400 (EDT)

dannym pushed a commit to branch master
in repository guix.

commit ceab612374b3eb3f6013b017454443fe47f104ef
Author: Danny Milosavljevic <address@hidden>
Date:   Tue Mar 26 12:22:47 2019 +0100

    gnu: docker: Use disjunct temp directories for probing.
    
    * gnu/packages/patches/docker-use-fewer-modprobes.patch: Use disjunct temp
    directories for probing.
---
 gnu/packages/patches/docker-use-fewer-modprobes.patch | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/gnu/packages/patches/docker-use-fewer-modprobes.patch 
b/gnu/packages/patches/docker-use-fewer-modprobes.patch
index 742cd60..2779e1b 100644
--- a/gnu/packages/patches/docker-use-fewer-modprobes.patch
+++ b/gnu/packages/patches/docker-use-fewer-modprobes.patch
@@ -51,7 +51,7 @@ See <https://github.com/moby/moby/pull/38930>.
 -      // proc/filesystems for when overlay is supported
 -      exec.Command("modprobe", "overlay").Run()
 +      // Access overlay filesystem so that Linux loads it (if possible).
-+      mountTarget, err := ioutil.TempDir("", "supportsOverlay")
++      mountTarget, err := ioutil.TempDir("", "supportsOverlay2")
 +      if err != nil {
 +              logrus.WithField("storage-driver", "overlay2").Error("Could not 
create temporary directory, so assuming that 'overlay' is not supported.")
 +              return graphdriver.ErrNotSupported
@@ -71,14 +71,14 @@ See <https://github.com/moby/moby/pull/38930>.
  
 -      // Check if kernel supports xfs filesystem or not.
 -      exec.Command("modprobe", "xfs").Run()
-+        mountTarget, err := ioutil.TempDir("", "supportsOverlay")
-+        if err != nil {
++      mountTarget, err := ioutil.TempDir("", "supportsXFS")
++      if err != nil {
 +              return errors.Wrapf(err, "error checking for xfs support")
-+        } else {
-+                /* The mounting will fail--after the module has been loaded.*/
-+                defer os.RemoveAll(mountTarget)
-+                unix.Mount("none", mountTarget, "xfs", 0, "")
-+        }
++      } else {
++              /* The mounting will fail--after the module has been loaded.*/
++              defer os.RemoveAll(mountTarget)
++              unix.Mount("none", mountTarget, "xfs", 0, "")
++      }
  
        f, err := os.Open("/proc/filesystems")
        if err != nil {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]