rake_vault 0.2.0 → 0.3.0.pre.2

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: 860786962846c498d1a92183fae7f9913fdc3ee99b73cd83391fda47f96fb2a7
4
- data.tar.gz: 9c50d3a19ccc88cac19bd747749f2fd592695ea3c257a136651ac83bd9337133
3
+ metadata.gz: a0f9d5756f3aae5f3c539dd2bd6178ca759e6d5fe6864ddf2ab1033d0ef0b5ef
4
+ data.tar.gz: 5b537c68b7a3ed3069e356cec0cc386206e8d2ac86d69a26c6556097386b584f
5
5
  SHA512:
6
- metadata.gz: 96343588dc07cf959ec54cb627cc4549b9b3abe6f66801de5854d40e14d773cd97185d6ebc4c4ef6e8a8ce86e7b9fb53a959dd958ab9debed07377191e88e7de
7
- data.tar.gz: 4f371be2845cdcefc56e55c3d2814fb47358a83632d62be2b3311bd58565389ae3ed2e6c0c0a27c72e0aa24d05b21b0bd4e6c60e5c608434a7e02ebe3a359891
6
+ metadata.gz: 3a20eb6fe39eed8e123aa78403922a503d89e84dc761b6664075e530d650697cd4c2ce21522240d2dcedf3ca11f42e3cd1b411c7c42f965dc60ccd6249cd1cd9
7
+ data.tar.gz: 3d4aa7dfb06508488f24b39742fd80d9d56c389b5ac1393594fa67b5c9ccf32202d9d5fcf9a509186f059846eccb89f521e1b38b74a7d65a3d63d151ac2cf70e
data/CODE_OF_CONDUCT.md CHANGED
@@ -5,9 +5,9 @@
5
5
  In the interest of fostering an open and welcoming environment, we as
6
6
  contributors and maintainers pledge to making participation in our project and
7
7
  our community a harassment-free experience for everyone, regardless of age, body
8
- size, disability, ethnicity, gender identity and expression, level of experience,
9
- nationality, personal appearance, race, religion, or sexual identity and
10
- orientation.
8
+ size, disability, ethnicity, gender identity and expression, level of
9
+ experience, nationality, personal appearance, race, religion, or sexual identity
10
+ and orientation.
11
11
 
12
12
  ## Our Standards
13
13
 
@@ -23,7 +23,7 @@ include:
23
23
  Examples of unacceptable behavior by participants include:
24
24
 
25
25
  * The use of sexualized language or imagery and unwelcome sexual attention or
26
- advances
26
+ advances
27
27
  * Trolling, insulting/derogatory comments, and personal or political attacks
28
28
  * Public or private harassment
29
29
  * Publishing others' private information, such as a physical or electronic
@@ -37,11 +37,11 @@ Project maintainers are responsible for clarifying the standards of acceptable
37
37
  behavior and are expected to take appropriate and fair corrective action in
38
38
  response to any instances of unacceptable behavior.
39
39
 
40
- Project maintainers have the right and responsibility to remove, edit, or
41
- reject comments, commits, code, wiki edits, issues, and other contributions
42
- that are not aligned to this Code of Conduct, or to ban temporarily or
43
- permanently any contributor for other behaviors that they deem inappropriate,
44
- threatening, offensive, or harmful.
40
+ Project maintainers have the right and responsibility to remove, edit, or reject
41
+ comments, commits, code, wiki edits, issues, and other contributions that are
42
+ not aligned to this Code of Conduct, or to ban temporarily or permanently any
43
+ contributor for other behaviors that they deem inappropriate, threatening,
44
+ offensive, or harmful.
45
45
 
46
46
  ## Scope
47
47
 
@@ -58,8 +58,9 @@ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
58
  reported by contacting the project team at maintainers@infrablocks.io. All
59
59
  complaints will be reviewed and investigated and will result in a response that
60
60
  is deemed necessary and appropriate to the circumstances. The project team is
61
- obligated to maintain confidentiality with regard to the reporter of an incident.
62
- Further details of specific enforcement policies may be posted separately.
61
+ obligated to maintain confidentiality with regard to the reporter of an
62
+ incident. Further details of specific enforcement policies may be posted
63
+ separately.
63
64
 
64
65
  Project maintainers who do not follow or enforce the Code of Conduct in good
65
66
  faith may face temporary or permanent repercussions as determined by other
@@ -67,8 +68,9 @@ members of the project's leadership.
67
68
 
68
69
  ## Attribution
69
70
 
70
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
- available at [http://contributor-covenant.org/version/1/4][version]
71
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage],
72
+ version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
72
73
 
73
74
  [homepage]: http://contributor-covenant.org
75
+
74
76
  [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- rake_vault (0.2.0)
4
+ rake_vault (0.3.0.pre.2)
5
5
  colored2 (~> 3.1)
6
6
  rake_dependencies (~> 3.1)
7
7
  rake_factory (~> 0.23)
@@ -11,65 +11,92 @@ PATH
11
11
  GEM
12
12
  remote: https://rubygems.org/
13
13
  specs:
14
- activesupport (7.0.4)
14
+ activesupport (7.1.1)
15
+ base64
16
+ bigdecimal
15
17
  concurrent-ruby (~> 1.0, >= 1.0.2)
18
+ connection_pool (>= 2.2.5)
19
+ drb
16
20
  i18n (>= 1.6, < 2)
17
21
  minitest (>= 5.1)
22
+ mutex_m
18
23
  tzinfo (~> 2.0)
19
- addressable (2.8.1)
24
+ addressable (2.8.5)
20
25
  public_suffix (>= 2.0.2, < 6.0)
21
26
  ast (2.4.2)
22
27
  aws-eventstream (1.2.0)
23
- aws-sigv4 (1.5.2)
28
+ aws-sigv4 (1.6.1)
24
29
  aws-eventstream (~> 1, >= 1.0.2)
30
+ base64 (0.1.1)
31
+ bigdecimal (3.1.4)
25
32
  colored2 (3.1.2)
26
- concurrent-ruby (1.1.10)
33
+ concurrent-ruby (1.2.2)
34
+ connection_pool (2.4.1)
27
35
  diff-lcs (1.5.0)
28
36
  docile (1.4.0)
29
- down (5.4.0)
37
+ down (5.4.1)
30
38
  addressable (~> 2.8)
31
- excon (0.95.0)
32
- faraday (2.7.2)
39
+ drb (2.1.1)
40
+ ruby2_keywords
41
+ excon (0.104.0)
42
+ faraday (2.7.11)
43
+ base64
33
44
  faraday-net_http (>= 2.0, < 3.1)
34
45
  ruby2_keywords (>= 0.0.4)
35
46
  faraday-net_http (3.0.2)
36
47
  gem-release (2.2.2)
48
+ git (1.18.0)
49
+ addressable (~> 2.8)
50
+ rchardet (~> 1.8)
37
51
  hamster (3.0.0)
38
52
  concurrent-ruby (~> 1.0)
39
- i18n (1.12.0)
53
+ i18n (1.14.1)
40
54
  concurrent-ruby (~> 1.0)
41
55
  immutable-struct (2.4.1)
42
56
  json (2.6.3)
57
+ language_server-protocol (3.17.0.3)
43
58
  lino (3.1.0)
44
59
  hamster (~> 3.0)
45
60
  open4 (~> 1.3)
46
61
  memfs (1.0.0)
47
62
  minitar (0.9)
48
- minitest (5.16.3)
49
- octokit (6.0.1)
63
+ minitest (5.20.0)
64
+ mutex_m (0.1.2)
65
+ octokit (6.1.1)
50
66
  faraday (>= 1, < 3)
51
67
  sawyer (~> 0.9)
52
68
  open4 (1.3.4)
53
- parallel (1.22.1)
54
- parser (3.1.3.0)
69
+ parallel (1.23.0)
70
+ parser (3.2.2.4)
55
71
  ast (~> 2.4.1)
56
- public_suffix (5.0.1)
72
+ racc
73
+ public_suffix (5.0.3)
74
+ racc (1.7.1)
57
75
  rainbow (3.1.1)
58
- rake (13.0.6)
76
+ rake (13.1.0)
59
77
  rake_circle_ci (0.11.0)
60
78
  colored2 (~> 3.1)
61
79
  excon (~> 0.72)
62
80
  rake_factory (~> 0.23)
63
81
  sshkey (~> 2.0)
64
- rake_dependencies (3.3.0)
82
+ rake_dependencies (3.5.0)
65
83
  down (~> 5.3)
66
84
  hamster (~> 3.0)
67
85
  minitar (~> 0.9)
68
86
  rake_factory (~> 0.23)
69
87
  rubyzip (>= 1.3)
70
- rake_factory (0.31.0)
88
+ rake_factory (0.32.0.pre.2)
71
89
  activesupport (>= 4)
72
90
  rake (~> 13.0)
91
+ rake_git (0.1.0.pre.8)
92
+ colored2 (~> 3.1)
93
+ git (~> 1.13, >= 1.13.2)
94
+ rake_factory (= 0.32.0.pre.2)
95
+ rake_git_crypt (0.1.0.pre.27)
96
+ colored2 (~> 3.1)
97
+ rake_factory (= 0.32.0.pre.2)
98
+ ruby_git_crypt (= 0.1.0.pre.2)
99
+ ruby_gpg2 (~> 0.6)
73
100
  rake_github (0.11.0)
74
101
  colored2 (~> 3.1)
75
102
  octokit (>= 4.16, < 7.0)
@@ -78,43 +105,54 @@ GEM
78
105
  rake_gpg (0.18.0)
79
106
  rake_factory (~> 0.23)
80
107
  ruby_gpg2 (~> 0.6)
81
- rake_ssh (0.8.0)
108
+ rake_ssh (0.10.0)
82
109
  colored2 (~> 3.1)
83
110
  rake_factory (~> 0.23)
84
111
  sshkey (~> 2.0)
85
- regexp_parser (2.6.1)
86
- rexml (3.2.5)
112
+ rchardet (1.8.0)
113
+ regexp_parser (2.8.2)
114
+ rexml (3.2.6)
87
115
  rspec (3.12.0)
88
116
  rspec-core (~> 3.12.0)
89
117
  rspec-expectations (~> 3.12.0)
90
118
  rspec-mocks (~> 3.12.0)
91
- rspec-core (3.12.0)
119
+ rspec-core (3.12.2)
92
120
  rspec-support (~> 3.12.0)
93
- rspec-expectations (3.12.1)
121
+ rspec-expectations (3.12.3)
94
122
  diff-lcs (>= 1.2.0, < 2.0)
95
123
  rspec-support (~> 3.12.0)
96
- rspec-mocks (3.12.1)
124
+ rspec-mocks (3.12.6)
97
125
  diff-lcs (>= 1.2.0, < 2.0)
98
126
  rspec-support (~> 3.12.0)
99
- rspec-support (3.12.0)
100
- rubocop (1.41.1)
127
+ rspec-support (3.12.1)
128
+ rubocop (1.57.2)
101
129
  json (~> 2.3)
130
+ language_server-protocol (>= 3.17.0)
102
131
  parallel (~> 1.10)
103
- parser (>= 3.1.2.1)
132
+ parser (>= 3.2.2.4)
104
133
  rainbow (>= 2.2.2, < 4.0)
105
134
  regexp_parser (>= 1.8, < 3.0)
106
135
  rexml (>= 3.2.5, < 4.0)
107
- rubocop-ast (>= 1.23.0, < 2.0)
136
+ rubocop-ast (>= 1.28.1, < 2.0)
108
137
  ruby-progressbar (~> 1.7)
109
- unicode-display_width (>= 1.4.0, < 3.0)
110
- rubocop-ast (1.24.0)
111
- parser (>= 3.1.1.0)
138
+ unicode-display_width (>= 2.4.0, < 3.0)
139
+ rubocop-ast (1.30.0)
140
+ parser (>= 3.2.1.0)
141
+ rubocop-capybara (2.19.0)
142
+ rubocop (~> 1.41)
143
+ rubocop-factory_bot (2.24.0)
144
+ rubocop (~> 1.33)
112
145
  rubocop-rake (0.6.0)
113
146
  rubocop (~> 1.0)
114
- rubocop-rspec (2.16.0)
115
- rubocop (~> 1.33)
116
- ruby-progressbar (1.11.0)
147
+ rubocop-rspec (2.25.0)
148
+ rubocop (~> 1.40)
149
+ rubocop-capybara (~> 2.17)
150
+ rubocop-factory_bot (~> 2.22)
151
+ ruby-progressbar (1.13.0)
117
152
  ruby2_keywords (0.0.5)
153
+ ruby_git_crypt (0.1.0.pre.2)
154
+ immutable-struct (~> 2.4)
155
+ lino (~> 3.0)
118
156
  ruby_gpg2 (0.10.0)
119
157
  lino (~> 3.0)
120
158
  ruby_vault (0.1.0)
@@ -131,14 +169,15 @@ GEM
131
169
  simplecov-html (0.12.3)
132
170
  simplecov_json_formatter (0.1.4)
133
171
  sshkey (2.0.0)
134
- tzinfo (2.0.5)
172
+ tzinfo (2.0.6)
135
173
  concurrent-ruby (~> 1.0)
136
- unicode-display_width (2.3.0)
137
- vault (0.17.0)
174
+ unicode-display_width (2.5.0)
175
+ vault (0.18.1)
138
176
  aws-sigv4
139
177
 
140
178
  PLATFORMS
141
179
  arm64-darwin-21
180
+ ruby
142
181
  x86_64-darwin-19
143
182
  x86_64-darwin-21
144
183
  x86_64-linux
@@ -150,6 +189,8 @@ DEPENDENCIES
150
189
  memfs
151
190
  rake
152
191
  rake_circle_ci
192
+ rake_git
193
+ rake_git_crypt
153
194
  rake_github
154
195
  rake_gpg
155
196
  rake_ssh
@@ -161,4 +202,4 @@ DEPENDENCIES
161
202
  simplecov
162
203
 
163
204
  BUNDLED WITH
164
- 2.4.1
205
+ 2.4.17
data/Rakefile CHANGED
@@ -1,19 +1,44 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'yaml'
4
3
  require 'rake_circle_ci'
4
+ require 'rake_git'
5
+ require 'rake_git_crypt'
5
6
  require 'rake_github'
6
- require 'rake_ssh'
7
7
  require 'rake_gpg'
8
- require 'securerandom'
8
+ require 'rake_ssh'
9
9
  require 'rspec/core/rake_task'
10
10
  require 'rubocop/rake_task'
11
+ require 'securerandom'
12
+ require 'yaml'
11
13
 
12
14
  task default: %i[
13
15
  library:fix
14
16
  test:unit
15
17
  ]
16
18
 
19
+ RakeGitCrypt.define_standard_tasks(
20
+ namespace: :git_crypt,
21
+
22
+ provision_secrets_task_name: :'secrets:provision',
23
+ destroy_secrets_task_name: :'secrets:destroy',
24
+
25
+ install_commit_task_name: :'git:commit',
26
+ uninstall_commit_task_name: :'git:commit',
27
+
28
+ gpg_user_key_paths: %w[
29
+ config/gpg
30
+ config/secrets/ci/gpg.public
31
+ ]
32
+ )
33
+
34
+ namespace :git do
35
+ RakeGit.define_commit_task(
36
+ argument_names: [:message]
37
+ ) do |t, args|
38
+ t.message = args.message
39
+ end
40
+ end
41
+
17
42
  namespace :encryption do
18
43
  namespace :directory do
19
44
  desc 'Ensure CI secrets directory exists.'
@@ -23,10 +48,12 @@ namespace :encryption do
23
48
  end
24
49
 
25
50
  namespace :passphrase do
26
- desc 'Generate encryption passphrase used by CI.'
51
+ desc 'Generate encryption passphrase for CI GPG key'
27
52
  task generate: ['directory:ensure'] do
28
- File.write('config/secrets/ci/encryption.passphrase',
29
- SecureRandom.base64(36))
53
+ File.write(
54
+ 'config/secrets/ci/encryption.passphrase',
55
+ SecureRandom.base64(36)
56
+ )
30
57
  end
31
58
  end
32
59
  end
@@ -51,12 +78,33 @@ namespace :keys do
51
78
  end
52
79
 
53
80
  namespace :secrets do
54
- desc 'Regenerate all generatable secrets.'
55
- task regenerate: %w[
81
+ namespace :directory do
82
+ desc 'Ensure secrets directory exists and is set up correctly'
83
+ task :ensure do
84
+ FileUtils.mkdir_p('config/secrets')
85
+ unless File.exist?('config/secrets/.unlocked')
86
+ File.write('config/secrets/.unlocked', 'true')
87
+ end
88
+ end
89
+ end
90
+
91
+ desc 'Generate all generatable secrets.'
92
+ task generate: %w[
56
93
  encryption:passphrase:generate
57
94
  keys:deploy:generate
58
95
  keys:gpg:generate
59
96
  ]
97
+
98
+ desc 'Provision all secrets.'
99
+ task provision: [:generate]
100
+
101
+ desc 'Delete all secrets.'
102
+ task :destroy do
103
+ rm_rf 'config/secrets'
104
+ end
105
+
106
+ desc 'Rotate all secrets.'
107
+ task rotate: [:'git_crypt:reinstall']
60
108
  end
61
109
 
62
110
  RuboCop::RakeTask.new
@@ -116,7 +164,6 @@ end
116
164
  namespace :pipeline do
117
165
  desc 'Prepare CircleCI Pipeline'
118
166
  task prepare: %i[
119
- circle_ci:project:follow
120
167
  circle_ci:env_vars:ensure
121
168
  circle_ci:checkout_keys:ensure
122
169
  circle_ci:ssh_keys:ensure
@@ -99,7 +99,6 @@ module RakeVault
99
99
  }
100
100
  end
101
101
 
102
- # rubocop:disable Naming/VariableNumber
103
102
  def platform_cpu_names
104
103
  @platform_cpu_names ||= {
105
104
  x86_64: 'amd64',
@@ -108,7 +107,6 @@ module RakeVault
108
107
  arm64: 'arm64'
109
108
  }
110
109
  end
111
- # rubocop:enable Naming/VariableNumber
112
110
 
113
111
  def uri_template
114
112
  @uri_template ||=
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module RakeVault
4
- VERSION = '0.2.0'
4
+ VERSION = '0.3.0.pre.2'
5
5
  end
data/rake_vault.gemspec CHANGED
@@ -48,6 +48,8 @@ Gem::Specification.new do |spec|
48
48
  spec.add_development_dependency 'memfs'
49
49
  spec.add_development_dependency 'rake'
50
50
  spec.add_development_dependency 'rake_circle_ci'
51
+ spec.add_development_dependency 'rake_git'
52
+ spec.add_development_dependency 'rake_git_crypt'
51
53
  spec.add_development_dependency 'rake_github'
52
54
  spec.add_development_dependency 'rake_gpg'
53
55
  spec.add_development_dependency 'rake_ssh'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rake_vault
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0.pre.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - InfraBlocks Maintainers
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-12-28 00:00:00.000000000 Z
11
+ date: 2023-10-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colored2
@@ -164,6 +164,34 @@ dependencies:
164
164
  - - ">="
165
165
  - !ruby/object:Gem::Version
166
166
  version: '0'
167
+ - !ruby/object:Gem::Dependency
168
+ name: rake_git
169
+ requirement: !ruby/object:Gem::Requirement
170
+ requirements:
171
+ - - ">="
172
+ - !ruby/object:Gem::Version
173
+ version: '0'
174
+ type: :development
175
+ prerelease: false
176
+ version_requirements: !ruby/object:Gem::Requirement
177
+ requirements:
178
+ - - ">="
179
+ - !ruby/object:Gem::Version
180
+ version: '0'
181
+ - !ruby/object:Gem::Dependency
182
+ name: rake_git_crypt
183
+ requirement: !ruby/object:Gem::Requirement
184
+ requirements:
185
+ - - ">="
186
+ - !ruby/object:Gem::Version
187
+ version: '0'
188
+ type: :development
189
+ prerelease: false
190
+ version_requirements: !ruby/object:Gem::Requirement
191
+ requirements:
192
+ - - ">="
193
+ - !ruby/object:Gem::Version
194
+ version: '0'
167
195
  - !ruby/object:Gem::Dependency
168
196
  name: rake_github
169
197
  requirement: !ruby/object:Gem::Requirement
@@ -319,9 +347,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
319
347
  version: '2.7'
320
348
  required_rubygems_version: !ruby/object:Gem::Requirement
321
349
  requirements:
322
- - - ">="
350
+ - - ">"
323
351
  - !ruby/object:Gem::Version
324
- version: '0'
352
+ version: 1.3.1
325
353
  requirements: []
326
354
  rubygems_version: 3.1.6
327
355
  signing_key: