examine 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitlab-ci.yml +3 -0
- data/Gemfile.lock +5 -5
- data/README.md +1 -1
- data/lib/examine/cli/clair.rb +6 -5
- data/lib/examine/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5cf198b3467cb13f6df21581c0aef817761ecefed231344d8a449c468feb0589
|
4
|
+
data.tar.gz: d8cd86723d4e7a41489659d08268ad15e4fa61289ea1423c8a22517668073ee3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b59d4abb283bcf0dda9327b90002cc82533e2a1fee851d5235e983323d23173a47261c0b1808842713bd6834ce8d347077b885bafd4928f9b8e48400b0800cab
|
7
|
+
data.tar.gz: 8fd0c0d806c61eb143aca5ae6222cbda4c45a4384dca929c2a17b5744c5ec7ad4e6d6ba0085f54317839b79824bd626af198537acdb96e149f9e1482a163e4eb
|
data/.gitlab-ci.yml
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
examine (0.1.
|
4
|
+
examine (0.1.3)
|
5
5
|
down (~> 4.8)
|
6
6
|
thor (~> 0.20)
|
7
7
|
|
8
8
|
GEM
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
|
-
addressable (2.
|
12
|
-
public_suffix (>= 2.0.2, <
|
11
|
+
addressable (2.7.0)
|
12
|
+
public_suffix (>= 2.0.2, < 5.0)
|
13
13
|
ast (2.4.0)
|
14
14
|
bundler-audit (0.6.1)
|
15
15
|
bundler (>= 1.2.0, < 3)
|
@@ -21,7 +21,7 @@ GEM
|
|
21
21
|
parallel (1.17.0)
|
22
22
|
parser (2.6.3.0)
|
23
23
|
ast (~> 2.4.0)
|
24
|
-
public_suffix (
|
24
|
+
public_suffix (4.0.6)
|
25
25
|
rainbow (3.0.0)
|
26
26
|
rake (10.5.0)
|
27
27
|
rspec (3.8.0)
|
@@ -63,4 +63,4 @@ DEPENDENCIES
|
|
63
63
|
rubocop-rspec (~> 1.22)
|
64
64
|
|
65
65
|
BUNDLED WITH
|
66
|
-
2.
|
66
|
+
2.1.4
|
data/README.md
CHANGED
@@ -26,7 +26,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
26
26
|
|
27
27
|
## Contributing
|
28
28
|
|
29
|
-
Bug reports and pull requests are welcome on GitLab at https://
|
29
|
+
Bug reports and pull requests are welcome on GitLab at https://github.com/mokhan/examine.
|
30
30
|
|
31
31
|
## License
|
32
32
|
|
data/lib/examine/cli/clair.rb
CHANGED
@@ -12,7 +12,6 @@ module Examine
|
|
12
12
|
'x86_64-linux' => 'clair-scanner_linux_amd64'
|
13
13
|
}.freeze
|
14
14
|
|
15
|
-
class_option :local_scan_version, desc: 'Version of the arminc/clair-local-scan image', default: 'latest', type: :string
|
16
15
|
class_option :scanner_version, desc: 'Version of the clair-scanner', default: 'v12', type: :string
|
17
16
|
class_option :url, desc: 'clair url', default: 'http://localhost:6060', type: :string
|
18
17
|
|
@@ -24,7 +23,7 @@ module Examine
|
|
24
23
|
spawn clair_db
|
25
24
|
wait_until clair_db_running?
|
26
25
|
|
27
|
-
spawn clair_local_scan
|
26
|
+
spawn clair_local_scan
|
28
27
|
wait_until clair_local_scan_running?
|
29
28
|
wait_until clair_local_scan_api_reachable?
|
30
29
|
end
|
@@ -66,6 +65,8 @@ module Examine
|
|
66
65
|
command = [
|
67
66
|
clair_exe, "-c #{options[:url]}",
|
68
67
|
"--ip #{clair_ip}",
|
68
|
+
'--threshold High',
|
69
|
+
'--reportAll=false',
|
69
70
|
"-r #{options[:report]}", "-l #{options[:log]}", image
|
70
71
|
]
|
71
72
|
command.insert(-2, "-w #{options[:whitelist]}") if options[:whitelist]
|
@@ -114,11 +115,11 @@ module Examine
|
|
114
115
|
end
|
115
116
|
|
116
117
|
def clair_db
|
117
|
-
'docker run -d --name clair-db arminc/clair-db:latest'
|
118
|
+
'docker run -d --name clair-db --network=host arminc/clair-db:latest'
|
118
119
|
end
|
119
120
|
|
120
|
-
def clair_local_scan
|
121
|
-
|
121
|
+
def clair_local_scan
|
122
|
+
'docker run --restart=unless-stopped -p 6060:6060 --add-host=postgres:0.0.0.0 --network=host -d --name clair arminc/clair-local-scan:latest'
|
122
123
|
end
|
123
124
|
|
124
125
|
def clair_local_scan_running?
|
data/lib/examine/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: examine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mo
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-10-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: down
|
@@ -170,7 +170,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
170
170
|
- !ruby/object:Gem::Version
|
171
171
|
version: '0'
|
172
172
|
requirements: []
|
173
|
-
rubygems_version: 3.
|
173
|
+
rubygems_version: 3.1.4
|
174
174
|
signing_key:
|
175
175
|
specification_version: 4
|
176
176
|
summary: Examine your software.
|