Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
dd89716e
Commit
dd89716e
authored
Jun 17, 2013
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
packer: An initial PostProcessor interface
parent
8f097399
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
1 deletion
+18
-1
packer/post_processor.go
packer/post_processor.go
+17
-0
packer/template.go
packer/template.go
+1
-1
No files found.
packer/post_processor.go
0 → 100644
View file @
dd89716e
package
packer
// A PostProcessor is responsible for taking an artifact of a build
// and doing some sort of post-processing to turn this into another
// artifact. An example of a post-processor would be something that takes
// the result of a build, compresses it, and returns a new artifact containing
// a single file of the prior artifact compressed.
type
PostProcessor
interface
{
// Configure is responsible for setting up configuration, storing
// the state for later, and returning and errors, such as validation
// errors.
Configure
(
interface
{})
error
// PostProcess takes a previously created Artifact and produces another
// Artifact. If an error occurs, it should return that error.
PostProcess
(
Artifact
)
(
Artifact
,
error
)
}
packer/template.go
View file @
dd89716e
...
...
@@ -14,7 +14,7 @@ type rawTemplate struct {
Builders
[]
map
[
string
]
interface
{}
Hooks
map
[
string
][]
string
Provisioners
[]
map
[
string
]
interface
{}
Outputs
[]
map
[
string
]
interface
{}
PostProcessors
[]
map
[
string
]
interface
{}
`json:"post-processors"`
}
// The Template struct represents a parsed template, parsed into the most
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment