Class: Packer::PostProcessor
- Inherits:
-
DataObject
show all
- Defined in:
- lib/packer/postprocessor.rb,
lib/packer/postprocessors/docker.rb,
lib/packer/postprocessors/vagrant.rb
Defined Under Namespace
Classes: DockerImport, DockerPush, DockerSave, DockerTag, UnrecognizedPostProcessorTypeError, Vagrant
Constant Summary
collapse
- DOCKER_IMPORT =
'docker-import'
- DOCKER_PUSH =
'docker-push'
- DOCKER_SAVE =
'docker-save'
- DOCKER_TAG =
'docker-tag'
- VAGRANT =
'vagrant'
- VALID_POST_PROCESSOR_TYPES =
[
DOCKER_IMPORT,
DOCKER_PUSH,
DOCKER_SAVE,
DOCKER_TAG,
VAGRANT
]
Instance Attribute Summary
Attributes inherited from DataObject
#data, #key_dependencies, #required
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from DataObject
#__add_array_of_array_of_strings, #__add_array_of_hashes, #__add_array_of_ints, #__add_array_of_strings, #__add_boolean, #__add_hash, #__add_integer, #__add_json, #__add_string, #__exclusive_key_error, #add_key_dependencies, #add_required, #deep_copy, #validate, #validate_key_dependencies, #validate_required
Constructor Details
Returns a new instance of PostProcessor.
41
42
43
44
|
# File 'lib/packer/postprocessor.rb', line 41
def initialize
super
self.add_required('type')
end
|
Class Method Details
.get_postprocessor(type) ⇒ Object
Instance Method Details
#except(buildname) ⇒ Object
53
54
55
56
57
58
|
# File 'lib/packer/postprocessor.rb', line 53
def except(buildname)
unless self.data.key? 'except'
self.data['except'] = []
end
self.data['except'] << buildname.to_s
end
|
60
61
62
|
# File 'lib/packer/postprocessor.rb', line 60
def keep_input_artifact(bool)
self.__add_boolean('keep_input_artifact', bool)
end
|
#only(buildname) ⇒ Object
46
47
48
49
50
51
|
# File 'lib/packer/postprocessor.rb', line 46
def only(buildname)
unless self.data.key? 'only'
self.data['only'] = []
end
self.data['only'] << buildname.to_s
end
|