awful 0.0.101 → 0.0.102
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/awful/ecr.rb +18 -0
- data/lib/awful/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: 507cb6aceaf2ecadde5e9691a17570fd4998bf21
|
4
|
+
data.tar.gz: 150879f71f9994a29645bb6c13bf794f93d5fc6f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ea7cc02925108b1a8822a7dd1956dda7849ce0120647151193591e8865d8eb4c625af7f664ab5a5d24d661295f508433ee6899fd8fc918d77ffdba2d72537c0f
|
7
|
+
data.tar.gz: 755e48925051c3e00f1c9abe80bd9397262df09958487da00740e1628e30d1b2d3be44bd7f92b7ed4268ce8b4ff4beffbc38d40f9ddea7d68273c386a86c53be
|
data/lib/awful/ecr.rb
CHANGED
@@ -78,5 +78,23 @@ module Awful
|
|
78
78
|
end
|
79
79
|
end
|
80
80
|
end
|
81
|
+
|
82
|
+
desc 'get REPO TAG[S]', 'get image details for all given TAGS'
|
83
|
+
def get(repository, *tags)
|
84
|
+
ids = tags.map do |tag|
|
85
|
+
{image_tag: tag}
|
86
|
+
end
|
87
|
+
ecr.batch_get_image(repository_name: repository, image_ids: ids).images.tap do |imgs|
|
88
|
+
imgs.each do |img|
|
89
|
+
puts YAML.dump(stringify_keys(img.to_h))
|
90
|
+
end
|
91
|
+
end
|
92
|
+
end
|
93
|
+
|
94
|
+
desc 'exists REPO TAG', 'test if repo with given tag exists in registry'
|
95
|
+
def exists(repository, tag)
|
96
|
+
imgs = ecr.batch_get_image(repository_name: repository, image_ids: [{image_tag: tag}]).images
|
97
|
+
(imgs.empty? ? false : true).tap(&method(:puts))
|
98
|
+
end
|
81
99
|
end
|
82
100
|
end
|
data/lib/awful/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: awful
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.102
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ric Lister
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-04-
|
11
|
+
date: 2016-04-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|