dapp 0.10.1 → 0.10.2
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/config/en/net_status.yml +1 -0
- data/lib/dapp/dimg/build/stage/ga_artifact_patch.rb +4 -0
- data/lib/dapp/dimg/image/docker.rb +11 -5
- data/lib/dapp/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c1c1c851ed5f27bd25dd4b3cf8bc1b27431fe81c
|
|
4
|
+
data.tar.gz: 32d35c1a530a102622ad85129d74d790a5711e4b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1ed7f72ee220ac672365bd00b5a1bc2b62ea10132816439b627c5df61a1297f66b7e008410bcf5f23257ee5e6e845a9c54f0361c79607c5c99faea352ba0c523
|
|
7
|
+
data.tar.gz: 495cf5dc364223895564aa19c99a6590cfe58a44f0a6c492c04aabd35c8111601cc49ac8a7ef8a20f27c96d519227706f57e4796dd701c9d33d40761ae4b5fee
|
data/config/en/net_status.yml
CHANGED
|
@@ -17,6 +17,7 @@ en:
|
|
|
17
17
|
built_id_not_defined: '`from.built_id` not defined!'
|
|
18
18
|
from_image_not_found: 'Image `%{name}` not found!'
|
|
19
19
|
unsupported_patch_format: "Unsupported patch format:\n\n%{patch}"
|
|
20
|
+
unsupported_docker_image_size_format: "Unsupported docker image size format `%{value}`"
|
|
20
21
|
command:
|
|
21
22
|
command_unexpected_dimgs_number: "Command can process only one dimg!\nAmbiguous dimg pattern: `%{dimgs_names}`!"
|
|
22
23
|
mrproper_required_option: "Expected command option `--improper-dev-mode-cache`, `--improper-cache-version-stages` or `--all`!"
|
|
@@ -105,18 +105,24 @@ module Dapp
|
|
|
105
105
|
.stdout
|
|
106
106
|
.lines
|
|
107
107
|
.each do |l|
|
|
108
|
-
name, id, created_at, size_field = l.split(';')
|
|
108
|
+
name, id, created_at, size_field = l.split(';').map(&:strip)
|
|
109
109
|
name = name.reverse.chomp('docker.io/'.reverse).reverse
|
|
110
110
|
size = begin
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
111
|
+
match = size_field.match(/^(\d+(\.\d+)?)\ ?(b|kb|mb|gb|tb)$/i)
|
|
112
|
+
raise Error::Build, code: :unsupported_docker_image_size_format, data: {value: size_field} unless match and match[1] and match[3]
|
|
113
|
+
|
|
114
|
+
number = match[1].to_f
|
|
115
|
+
unit = match[3].downcase
|
|
116
|
+
|
|
117
|
+
coef = case unit
|
|
118
|
+
when 'b' then 0
|
|
114
119
|
when 'kb' then 1
|
|
115
120
|
when 'mb' then 2
|
|
116
121
|
when 'gb' then 3
|
|
117
122
|
when 'tb' then 4
|
|
118
123
|
end
|
|
119
|
-
|
|
124
|
+
|
|
125
|
+
number * (1000**coef)
|
|
120
126
|
end
|
|
121
127
|
cache[name] = { id: id, created_at: created_at, size: size }
|
|
122
128
|
end
|
data/lib/dapp/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dapp
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.10.
|
|
4
|
+
version: 0.10.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dmitry Stolyarov
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-04-
|
|
11
|
+
date: 2017-04-07 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: mixlib-shellout
|