itamae 1.10.0 → 1.12.5

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.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/test.yml +203 -0
  3. data/.gitignore +1 -0
  4. data/CHANGELOG.md +144 -1
  5. data/README.md +2 -3
  6. data/Rakefile +50 -42
  7. data/bin/itamae +0 -1
  8. data/itamae.gemspec +2 -2
  9. data/lib/itamae/backend.rb +20 -5
  10. data/lib/itamae/cli.rb +14 -9
  11. data/lib/itamae/definition.rb +0 -2
  12. data/lib/itamae/logger.rb +5 -1
  13. data/lib/itamae/mash.rb +7 -0
  14. data/lib/itamae/node.rb +4 -4
  15. data/lib/itamae/notification.rb +0 -2
  16. data/lib/itamae/recipe.rb +20 -3
  17. data/lib/itamae/resource/base.rb +3 -3
  18. data/lib/itamae/resource/directory.rb +0 -2
  19. data/lib/itamae/resource/execute.rb +0 -2
  20. data/lib/itamae/resource/file.rb +43 -6
  21. data/lib/itamae/resource/gem_package.rb +0 -2
  22. data/lib/itamae/resource/git.rb +5 -7
  23. data/lib/itamae/resource/group.rb +0 -2
  24. data/lib/itamae/resource/http_request.rb +12 -3
  25. data/lib/itamae/resource/link.rb +0 -2
  26. data/lib/itamae/resource/local_ruby_block.rb +0 -2
  27. data/lib/itamae/resource/package.rb +3 -3
  28. data/lib/itamae/resource/remote_directory.rb +1 -3
  29. data/lib/itamae/resource/remote_file.rb +0 -2
  30. data/lib/itamae/resource/service.rb +0 -2
  31. data/lib/itamae/resource/template.rb +8 -4
  32. data/lib/itamae/resource/user.rb +0 -2
  33. data/lib/itamae/resource.rb +0 -1
  34. data/lib/itamae/runner.rb +3 -4
  35. data/lib/itamae/version.rb +1 -1
  36. data/lib/itamae.rb +1 -1
  37. data/spec/integration/default_spec.rb +26 -32
  38. data/spec/integration/docker_spec.rb +29 -0
  39. data/spec/integration/local_spec.rb +6 -0
  40. data/spec/integration/ordinary_user_spec.rb +108 -0
  41. data/spec/integration/recipes/default.rb +10 -48
  42. data/spec/integration/recipes/docker.rb +44 -0
  43. data/spec/integration/recipes/local.rb +19 -0
  44. data/spec/integration/recipes/ordinary_user.rb +109 -0
  45. data/spec/integration/recipes/toplevel_module.rb +6 -0
  46. data/spec/integration/recipes/variables.rb +14 -0
  47. data/spec/unit/lib/itamae/backend_spec.rb +10 -10
  48. data/tasks/integration_local_spec.rb +117 -0
  49. metadata +26 -9
  50. data/.travis.yml +0 -39
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: itamae
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.0
4
+ version: 1.12.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryota Arai
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2018-11-12 00:00:00.000000000 Z
13
+ date: 2021-12-31 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: thor
@@ -92,14 +92,14 @@ dependencies:
92
92
  name: bundler
93
93
  requirement: !ruby/object:Gem::Requirement
94
94
  requirements:
95
- - - "~>"
95
+ - - ">="
96
96
  - !ruby/object:Gem::Version
97
97
  version: '1.3'
98
98
  type: :development
99
99
  prerelease: false
100
100
  version_requirements: !ruby/object:Gem::Requirement
101
101
  requirements:
102
- - - "~>"
102
+ - - ">="
103
103
  - !ruby/object:Gem::Version
104
104
  version: '1.3'
105
105
  - !ruby/object:Gem::Dependency
@@ -164,14 +164,14 @@ dependencies:
164
164
  requirements:
165
165
  - - "~>"
166
166
  - !ruby/object:Gem::Version
167
- version: '1.20'
167
+ version: '2'
168
168
  type: :development
169
169
  prerelease: false
170
170
  version_requirements: !ruby/object:Gem::Requirement
171
171
  requirements:
172
172
  - - "~>"
173
173
  - !ruby/object:Gem::Version
174
- version: '1.20'
174
+ version: '2'
175
175
  - !ruby/object:Gem::Dependency
176
176
  name: fakefs
177
177
  requirement: !ruby/object:Gem::Requirement
@@ -210,9 +210,9 @@ executables:
210
210
  extensions: []
211
211
  extra_rdoc_files: []
212
212
  files:
213
+ - ".github/workflows/test.yml"
213
214
  - ".gitignore"
214
215
  - ".rspec"
215
- - ".travis.yml"
216
216
  - CHANGELOG.md
217
217
  - Gemfile
218
218
  - LICENSE.txt
@@ -246,6 +246,7 @@ files:
246
246
  - lib/itamae/handler/json.rb
247
247
  - lib/itamae/handler_proxy.rb
248
248
  - lib/itamae/logger.rb
249
+ - lib/itamae/mash.rb
249
250
  - lib/itamae/node.rb
250
251
  - lib/itamae/notification.rb
251
252
  - lib/itamae/recipe.rb
@@ -270,22 +271,30 @@ files:
270
271
  - lib/itamae/runner.rb
271
272
  - lib/itamae/version.rb
272
273
  - spec/integration/default_spec.rb
274
+ - spec/integration/docker_spec.rb
275
+ - spec/integration/local_spec.rb
276
+ - spec/integration/ordinary_user_spec.rb
273
277
  - spec/integration/recipes/default.rb
274
278
  - spec/integration/recipes/default2.rb
275
279
  - spec/integration/recipes/define/default.rb
276
280
  - spec/integration/recipes/define/files/remote_file_in_definition
277
281
  - spec/integration/recipes/define/files/remote_file_in_definition_2
278
282
  - spec/integration/recipes/define/files/remote_file_in_definition_3
283
+ - spec/integration/recipes/docker.rb
279
284
  - spec/integration/recipes/dry_run.rb
280
285
  - spec/integration/recipes/files/empty_file
281
286
  - spec/integration/recipes/files/remote_file_auto
282
287
  - spec/integration/recipes/hello.erb
283
288
  - spec/integration/recipes/hello.txt
284
289
  - spec/integration/recipes/included.rb
290
+ - spec/integration/recipes/local.rb
285
291
  - spec/integration/recipes/node.json
292
+ - spec/integration/recipes/ordinary_user.rb
286
293
  - spec/integration/recipes/redefine.rb
287
294
  - spec/integration/recipes/templates/empty_file.erb
288
295
  - spec/integration/recipes/templates/template_auto.erb
296
+ - spec/integration/recipes/toplevel_module.rb
297
+ - spec/integration/recipes/variables.rb
289
298
  - spec/integration/spec_helper.rb
290
299
  - spec/unit/lib/itamae/backend_spec.rb
291
300
  - spec/unit/lib/itamae/handler/base_spec.rb
@@ -299,6 +308,7 @@ files:
299
308
  - spec/unit/lib/itamae/resource_spec.rb
300
309
  - spec/unit/lib/itamae/runner_spec.rb
301
310
  - spec/unit/spec_helper.rb
311
+ - tasks/integration_local_spec.rb
302
312
  homepage: https://itamae.kitchen/
303
313
  licenses:
304
314
  - MIT
@@ -321,29 +331,36 @@ required_rubygems_version: !ruby/object:Gem::Requirement
321
331
  - !ruby/object:Gem::Version
322
332
  version: '0'
323
333
  requirements: []
324
- rubyforge_project:
325
- rubygems_version: 2.7.7
334
+ rubygems_version: 3.2.3
326
335
  signing_key:
327
336
  specification_version: 4
328
337
  summary: Simple Configuration Management Tool
329
338
  test_files:
330
339
  - spec/integration/default_spec.rb
340
+ - spec/integration/docker_spec.rb
341
+ - spec/integration/local_spec.rb
342
+ - spec/integration/ordinary_user_spec.rb
331
343
  - spec/integration/recipes/default.rb
332
344
  - spec/integration/recipes/default2.rb
333
345
  - spec/integration/recipes/define/default.rb
334
346
  - spec/integration/recipes/define/files/remote_file_in_definition
335
347
  - spec/integration/recipes/define/files/remote_file_in_definition_2
336
348
  - spec/integration/recipes/define/files/remote_file_in_definition_3
349
+ - spec/integration/recipes/docker.rb
337
350
  - spec/integration/recipes/dry_run.rb
338
351
  - spec/integration/recipes/files/empty_file
339
352
  - spec/integration/recipes/files/remote_file_auto
340
353
  - spec/integration/recipes/hello.erb
341
354
  - spec/integration/recipes/hello.txt
342
355
  - spec/integration/recipes/included.rb
356
+ - spec/integration/recipes/local.rb
343
357
  - spec/integration/recipes/node.json
358
+ - spec/integration/recipes/ordinary_user.rb
344
359
  - spec/integration/recipes/redefine.rb
345
360
  - spec/integration/recipes/templates/empty_file.erb
346
361
  - spec/integration/recipes/templates/template_auto.erb
362
+ - spec/integration/recipes/toplevel_module.rb
363
+ - spec/integration/recipes/variables.rb
347
364
  - spec/integration/spec_helper.rb
348
365
  - spec/unit/lib/itamae/backend_spec.rb
349
366
  - spec/unit/lib/itamae/handler/base_spec.rb
data/.travis.yml DELETED
@@ -1,39 +0,0 @@
1
- language: ruby
2
- sudo: required
3
- services:
4
- - docker
5
- rvm:
6
- - 2.3
7
- - 2.4
8
- - 2.5
9
- - ruby-head
10
- bundler_args: "--jobs=4 --retry=3"
11
- cache:
12
- bundler: true
13
- directories:
14
- - $HOME/docker
15
-
16
- before_cache:
17
- # Save tagged docker images
18
- - >
19
- mkdir -p $HOME/docker && docker images -a --filter='dangling=false' --format '{{.Repository}}:{{.Tag}} {{.ID}}'
20
- | xargs -n 2 -t sh -c 'test -e $HOME/docker/$1.tar.gz || docker save $0 | gzip -2 > $HOME/docker/$1.tar.gz'
21
-
22
- before_install:
23
- - gem update --system --no-document
24
- - gem install bundler --no-document
25
- # Load cached docker images
26
- - if [[ -d $HOME/docker ]]; then ls $HOME/docker/*.tar.gz | xargs -I {file} sh -c "zcat {file} | docker load"; fi
27
-
28
- script:
29
- - bundle exec rake spec
30
- notifications:
31
- email: false
32
- slack:
33
- secure: PcecHsVS6lw89K5PllW8xFlzu0d04p6lYfxlUZL0/yp9flAczElJME4RshSMSkbnu5e2Iw8KUA2xB1jkAzDo9qYoXveaKyjkFUOb1ZxYIVxzzfoDDwUNTMmSoyjZjvbeBUcpxxmxy6nXa3zS+gA2ohqWhS9WTTlTqyM5RriDjZ8=
34
- matrix:
35
- allow_failures:
36
- - rvm: ruby-head
37
- branches:
38
- only:
39
- - master