]> git.e2factory.org Git - e2factory.git/commitdiff
e2build: Warn about deploying to a disabled releases server
authorTobias Ulmer <tu@emlix.com>
Fri, 23 May 2014 16:34:04 +0000 (18:34 +0200)
committerTobias Ulmer <tu@emlix.com>
Wed, 16 Nov 2016 14:41:18 +0000 (15:41 +0100)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
local/e2build.lua

index 5e21f2ce9e45f533dc2271c05b13120b3bce6864..fd594c8ca9ad39784fe18c972a4bbd6b5dc72702 100644 (file)
@@ -931,17 +931,26 @@ local function deploy(info, r, tmpdir)
         return true
     end
 
+
     e2lib.logf(1, "deploying %s to %s:%s", r, server, location)
+    local cache_flags = {}
+
     for _,f in ipairs(files) do
-        local sourcefile = e2lib.join(resdir, f)
-        local location1 = e2lib.join(location, r, f)
-        local cache_flags = {}
-        local rc, re = cache.push_file(info.cache, sourcefile, server, location1,
+        local sourcefile, location1
+
+        sourcefile = e2lib.join(resdir, f)
+        location1 = e2lib.join(location, r, f)
+        rc, re = cache.push_file(info.cache, sourcefile, server, location1,
             cache_flags)
         if not rc then
             return false, re
         end
     end
+    if cache.writeback_state(info.cache, server, cache_flags) == false then
+        e2lib.warnf("WOTHER",
+            "Writeback is disabled for server %q. Release not deployed!", server)
+    end
+
     return true
 end