packer-config 1.6.4 → 1.6.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/COPYRIGHT +9 -8
- data/RELEASENOTES.md +7 -0
- data/lib/packer-config.rb +9 -0
- data/lib/packer/builders/docker.rb +10 -5
- data/lib/packer/version.rb +1 -1
- data/packer-config.gemspec +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3df09c4a516dbd12740044b0f3b2b67fe29ddc20
|
4
|
+
data.tar.gz: a532ec15bc696505a71e3f748459f5fafc59fada
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 56cd904986e3748efc45e275df8414b0c32384baf074f6778639d9397658e2b712c5d975452bbd47c958f8ab21746ef0947b520b300710336066a1772933cdfa
|
7
|
+
data.tar.gz: 837535c295af744ed00dfaa649e366ae530287cd77f35139798541b152c4e0db67b6881ad137e1112b554827c298d1e3ea3e0297da14b823b0cbb9bf32584579
|
data/COPYRIGHT
CHANGED
@@ -2,14 +2,15 @@ Unless specified otherwise, all content copyright the respective contributors.
|
|
2
2
|
|
3
3
|
Including, but not limited to:
|
4
4
|
|
5
|
-
Ian Chesal
|
6
|
-
Fraser Cobb
|
7
|
-
Greg Poirier
|
8
|
-
Greg Diamond
|
9
|
-
Enzo Rivello
|
10
|
-
Edwin Biemond
|
11
|
-
Andrei Shiniti Nakagawa
|
12
|
-
Kevin Formsma
|
5
|
+
[Ian Chesal](https://github.com/ianchesal)
|
6
|
+
[Fraser Cobb](https://github.com/frasercobb)
|
7
|
+
[Greg Poirier](https://github.com/grepory)
|
8
|
+
[Greg Diamond](https://github.com/diamond29)
|
9
|
+
[Enzo Rivello](https://github.com/enzor)
|
10
|
+
[Edwin Biemond](https://github.com/biemond)
|
11
|
+
[Andrei Shiniti Nakagawa](https://github.com/shinitiandrei)
|
12
|
+
[Kevin Formsma](https://github.com/arothian)
|
13
|
+
[sabishiii](https://github.com/sabishiii)
|
13
14
|
|
14
15
|
For licensing information please see LICENSE. Copyright holders contributing to
|
15
16
|
this project agree to have their contributions licensed under the terms of the
|
data/RELEASENOTES.md
CHANGED
@@ -1,5 +1,11 @@
|
|
1
1
|
# packer-config Release Notes
|
2
2
|
|
3
|
+
## 1.6.5
|
4
|
+
|
5
|
+
* Docker builder: Expose the `commit` and `changes` parameters. (via [sabishiii])
|
6
|
+
* Made the `commit` parameter mutually exclusive with the `export_path` one. (via [sabishiii])
|
7
|
+
* Unchained postprocessors: added a Packer::Config boolean switch to nest the array of postprocessors (via [sabishiii])
|
8
|
+
|
3
9
|
## 1.6.4
|
4
10
|
|
5
11
|
* Add support for the manifest post-provisioner (via [arothian])
|
@@ -79,3 +85,4 @@
|
|
79
85
|
[biemond]: https://github.com/biemond
|
80
86
|
[shinitiandrei]: https://github.com/shinitiandrei
|
81
87
|
[arothian]: https://github.com/arothian
|
88
|
+
[sabishiii]: https://github.com/sabishiii
|
data/lib/packer-config.rb
CHANGED
@@ -17,6 +17,7 @@ module Packer
|
|
17
17
|
attr_accessor :provisioners
|
18
18
|
attr_accessor :packer
|
19
19
|
attr_accessor :packer_options
|
20
|
+
attr_accessor :chained_postprocessors
|
20
21
|
attr_reader :macro
|
21
22
|
attr_reader :envvar
|
22
23
|
attr_reader :output_file
|
@@ -34,6 +35,11 @@ module Packer
|
|
34
35
|
self.packer_options = []
|
35
36
|
self.macro = Macro.new
|
36
37
|
self.envvar = EnvVar.new
|
38
|
+
self.chained_postprocessors = true
|
39
|
+
end
|
40
|
+
|
41
|
+
def chained_postprocessors?
|
42
|
+
self.chained_postprocessors ? true : false
|
37
43
|
end
|
38
44
|
|
39
45
|
def validate(verbose: false)
|
@@ -79,6 +85,9 @@ module Packer
|
|
79
85
|
self.postprocessors.each do |thing|
|
80
86
|
data_copy['post-processors'].push(thing.deep_copy)
|
81
87
|
end
|
88
|
+
unless self.chained_postprocessors?
|
89
|
+
data_copy['post-processors'] = [data_copy['post-processors']]
|
90
|
+
end
|
82
91
|
end
|
83
92
|
case format
|
84
93
|
when 'json'
|
@@ -8,14 +8,15 @@ module Packer
|
|
8
8
|
def initialize
|
9
9
|
super
|
10
10
|
self.data['type'] = DOCKER
|
11
|
-
self.add_required(
|
12
|
-
'export_path',
|
13
|
-
'image'
|
14
|
-
)
|
11
|
+
self.add_required('image')
|
15
12
|
end
|
16
13
|
|
17
14
|
def export_path(path)
|
18
|
-
self.__add_string('export_path', path)
|
15
|
+
self.__add_string('export_path', path, ['commit'])
|
16
|
+
end
|
17
|
+
|
18
|
+
def commit(bool)
|
19
|
+
self.__add_boolean('commit', bool, ['export_path'])
|
19
20
|
end
|
20
21
|
|
21
22
|
def image(name)
|
@@ -26,6 +27,10 @@ module Packer
|
|
26
27
|
self.__add_boolean('pull', bool)
|
27
28
|
end
|
28
29
|
|
30
|
+
def changes(changes)
|
31
|
+
self.__add_array_of_strings('changes', changes)
|
32
|
+
end
|
33
|
+
|
29
34
|
def run_command(commands)
|
30
35
|
self.__add_array_of_strings('run_command', commands)
|
31
36
|
end
|
data/lib/packer/version.rb
CHANGED
data/packer-config.gemspec
CHANGED
@@ -6,7 +6,7 @@ require 'packer/version'
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
7
|
spec.name = 'packer-config'
|
8
8
|
spec.version = Packer::VERSION
|
9
|
-
spec.authors = ["Ian Chesal", "Fraser Cobb", "Greg Poirier", "Matasano Security", "Greg Diamond", "Enzo Rivello", "Edwin Biemond", "Andrei Shiniti Nakagawa", "Kevin Formsma"]
|
9
|
+
spec.authors = ["Ian Chesal", "Fraser Cobb", "Greg Poirier", "Matasano Security", "Greg Diamond", "Enzo Rivello", "Edwin Biemond", "Andrei Shiniti Nakagawa", "Kevin Formsma", "sabishiii"]
|
10
10
|
spec.email = %w(ian.chesal@gmail.com)
|
11
11
|
spec.summary = 'An object model to build packer.io configurations in Ruby.'
|
12
12
|
spec.description = <<-END
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: packer-config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ian Chesal
|
@@ -13,10 +13,11 @@ authors:
|
|
13
13
|
- Edwin Biemond
|
14
14
|
- Andrei Shiniti Nakagawa
|
15
15
|
- Kevin Formsma
|
16
|
+
- sabishiii
|
16
17
|
autorequire:
|
17
18
|
bindir: bin
|
18
19
|
cert_chain: []
|
19
|
-
date: 2019-
|
20
|
+
date: 2019-07-27 00:00:00.000000000 Z
|
20
21
|
dependencies: []
|
21
22
|
description: |
|
22
23
|
Building the Packer JSON configurations in raw JSON can be quite an adventure.
|