deploy_rubygem 0.60.15 → 0.60.17

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 42d5653bfbf47c8c4455f7ee9561f6116546f541ef3a8e2b3b3a0e7ad20c17fb
4
- data.tar.gz: 7862b99fd977bcd1e7694c9dc07ac01c722d4a3e7de06de7479b1235984d4dc3
3
+ metadata.gz: 7297b217dc970f4c1c07c2820d1073420b8e31154b371551306bbed62d2893fa
4
+ data.tar.gz: c4540e278101511b18e4eee740d9c646aa111ce4db0ca9ae3c15ba7bf792887e
5
5
  SHA512:
6
- metadata.gz: 423aad8a50c5bd6037d9b4d28a896fdfa4286eb7e84006c90a0e528ef94515dc5879dcf1034e3881e6024ed7af64b083b20c0c3b8dcb1c468bad23d9bd796e3b
7
- data.tar.gz: 312f81bf90a3ba8d07479b3d6156c63192f7848d2764d0e00b869a71e6d6224f759a78ecdd36ee045c1e35afb8683973c1397e05051375ea49e06ee11fca81dc
6
+ metadata.gz: 6ef147a37dcc8fbe818eefe67a06f582a38d8212cf388926cb63ebc2f3472938ee0af21eff8e2eab01219bd704106adf2858e21ce27945dcec5e2785610a34ab
7
+ data.tar.gz: b0142f5b13de78cf70b403e650de62850758387f4959b02f3e9170a60aef2418e6205a678657ebf37a4521069fa19edc8375a2bf7ad2f732a21d05245562701a
checksums.yaml.gz.sig CHANGED
Binary file
data/Rakefile CHANGED
@@ -15,7 +15,7 @@ task default: %i[test_framework build install:local]
15
15
  task cicd: %i[default release test_version]
16
16
  task test_version: %i[install compliance]
17
17
  task :compliance do
18
- system('inspec exec git@github.com:JimboDragonGit/rubygem_baseline.git --input-file compliance.yml')
18
+ # system('inspec exec git@github.com:JimboDragonGit/rubygem_baseline.git --input-file compliance.yml')
19
19
  end
20
20
  task developper: %i[push cicd]
21
21
  task :push do
@@ -5,7 +5,7 @@
5
5
  module DeployRubygem
6
6
  # Using Inspec to deploy and manage Inspec
7
7
  class Inspec
8
- attr_reader :inspec_name, :input_file
8
+ attr_reader :inspec_name, :input_file, :waiver_file
9
9
 
10
10
  def initialize(inspec_name, input_file = nil, waiver_file = nil)
11
11
  @inspec_name = inspec_name
@@ -13,12 +13,7 @@ module DeployRubygem
13
13
  @waiver_file = waiver_file
14
14
  end
15
15
 
16
- def apply
17
- puts "ActuaL Dir #{Dir.pwd}"
18
- puts "inspec_name = #{inspec_name}"
19
- puts "input_file = #{input_file}"
20
- puts "waiver_file = #{waiver_file}"
21
- system("inspec check compliance/profiles/#{inspec_name}")
16
+ def inspec_options
22
17
  cmd_opt = []
23
18
 
24
19
  unless input_file.nil?
@@ -30,7 +25,21 @@ module DeployRubygem
30
25
  cmd_opt << '--waiver-file'
31
26
  cmd_opt << waiver_file
32
27
  end
33
- system("inspec exec compliance/profiles/#{inspec_name} #{cmd_opt.join(' ')}")
28
+ cmd_opt
29
+ end
30
+
31
+ def check
32
+ system("inspec check compliance/profiles/#{inspec_name}")
33
+ end
34
+
35
+ def apply
36
+ puts "ActuaL Dir #{Dir.pwd}"
37
+ puts "inspec_name = #{inspec_name}"
38
+ puts "input_file = #{input_file}"
39
+ puts "waiver_file = #{waiver_file}"
40
+
41
+ check
42
+ system("inspec exec compliance/profiles/#{inspec_name} #{inspec_options.join(' ')}")
34
43
  end
35
44
 
36
45
  def update
@@ -38,5 +47,15 @@ module DeployRubygem
38
47
  system("rm compliance/profiles/#{inspec_name}/inspec.lock")
39
48
  system("inspec vendor compliance/profiles/#{inspec_name}")
40
49
  end
50
+
51
+ def save_as_html(html_file)
52
+ check
53
+ system("inspec exec compliance/profiles/#{inspec_name} #{cmd_opt.join(' ')} --reporter html:#{html_file}")
54
+ end
55
+
56
+ def as_json
57
+ check
58
+ `inspec exec compliance/profiles/#{inspec_name} #{cmd_opt.join(' ')} --reporter json")`
59
+ end
41
60
  end
42
61
  end
@@ -17,5 +17,5 @@ module DeployRubygem
17
17
  end
18
18
 
19
19
  # VERSION = new_deploy_rubygem.gvb_version.short_version
20
- VERSION = '0.60.15'
20
+ VERSION = '0.60.17'
21
21
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: deploy_rubygem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.60.15
4
+ version: 0.60.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jimmy Provencher
@@ -33,7 +33,7 @@ cert_chain:
33
33
  n6Pwa3EckU/5n8N6gUJTAmGyu6Ncu1pbsZtH450+BJ2z82JNXomdFYlnG8+1XNlj
34
34
  3M1sBFUHvqrBg2hQkQcLHokmQYrYsRK5A7HrxwKcmwM=
35
35
  -----END CERTIFICATE-----
36
- date: 2024-06-08 00:00:00.000000000 Z
36
+ date: 2024-06-09 00:00:00.000000000 Z
37
37
  dependencies:
38
38
  - !ruby/object:Gem::Dependency
39
39
  name: rspec
metadata.gz.sig CHANGED
Binary file