linecook-gem 0.7.22 → 0.7.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/bin/linecook +1 -0
- data/lib/linecook-gem/baker/docker.rb +4 -0
- data/lib/linecook-gem/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 346dd5e272f05b7f6ff7af641c93daa667b55e0e
|
|
4
|
+
data.tar.gz: 86ab523201c74aa25a65ace836d5fcfe5ee64916
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c97f147b96169e588176ec2fbc6f6d06409c6c62a70ce74d11e7d3b1db8bb6accca1ade4a13e81401508d1ac76d14bdae6a536b69654afc7bdc5bbaff1a6556c
|
|
7
|
+
data.tar.gz: 8aef4e61961447c0fdcc7bbe46bac1e2986792ffc22a2bf3e4da39835cbf77bb85a30afb801c994afa8577a7de849887e543d23ec27179959b5c4f52003112df
|
data/bin/linecook
CHANGED
|
@@ -7,6 +7,7 @@ begin
|
|
|
7
7
|
ENV['THOR_DEBUG'] = '1'
|
|
8
8
|
etime = Benchmark.realtime { Linecook::CLI.start(ARGV) }
|
|
9
9
|
$stderr.puts "Completed in #{etime}s"
|
|
10
|
+
exit(0)
|
|
10
11
|
rescue Thor::UndefinedCommandError, Thor::UnknownArgumentError, Thor::AmbiguousCommandError, Thor::InvocationError => e
|
|
11
12
|
$stderr.puts(e.message)
|
|
12
13
|
exit(64)
|
|
@@ -27,6 +27,10 @@ module Linecook
|
|
|
27
27
|
def save
|
|
28
28
|
FileUtils.mkdir_p(File.dirname(@image.path))
|
|
29
29
|
with_retries(5) do
|
|
30
|
+
# You might be wondering "wtf is this"? And how!
|
|
31
|
+
# tl;dr, we want to take the bitwise OR of the return codes for everything in the pipe.
|
|
32
|
+
# so, if any command in the pipe fails, treat the whole pipe to have failed.
|
|
33
|
+
# otherwise, we could end up with xz compressing an invalid export, and treating it as OK.
|
|
30
34
|
status = system("/bin/bash -c 'docker export #{@image.id} | xz -T 0 -0 > #{@image.path}; exit $((${PIPESTATUS[0]} | ${PIPESTATUS[1]}))'")
|
|
31
35
|
fail "Export failed" unless status
|
|
32
36
|
end
|
data/lib/linecook-gem/version.rb
CHANGED