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
a9f63871
Commit
a9f63871
authored
Jul 05, 2013
by
Mitchell Hashimoto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
post-processor/vagrant: properly forward config into provider [GH-129]
parent
eba9834b
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
4 deletions
+12
-4
CHANGELOG.md
CHANGELOG.md
+5
-0
post-processor/vagrant/post-processor.go
post-processor/vagrant/post-processor.go
+7
-4
No files found.
CHANGELOG.md
View file @
a9f63871
...
...
@@ -10,6 +10,11 @@ IMPROVEMENTS:
*
virtualbox: Delete the packer-made SSH port forwarding prior to
exporting the VM.
BUG FIXES:
*
vagrant: Properly configure the provider-specific post-processors so
things like
`vagrantfile_template`
work. [GH-129]
## 0.1.4 (July 2, 2013)
FEATURES:
...
...
post-processor/vagrant/post-processor.go
View file @
a9f63871
...
...
@@ -24,11 +24,15 @@ type Config struct {
}
type
PostProcessor
struct
{
config
Config
premade
map
[
string
]
packer
.
PostProcessor
config
Config
premade
map
[
string
]
packer
.
PostProcessor
rawConfigs
[]
interface
{}
}
func
(
p
*
PostProcessor
)
Configure
(
raws
...
interface
{})
error
{
// Store the raw configs for usage later
p
.
rawConfigs
=
raws
for
_
,
raw
:=
range
raws
{
err
:=
mapstructure
.
Decode
(
raw
,
&
p
.
config
)
if
err
!=
nil
{
...
...
@@ -93,8 +97,7 @@ func (p *PostProcessor) PostProcess(ui packer.Ui, artifact packer.Artifact) (pac
return
nil
,
false
,
fmt
.
Errorf
(
"Vagrant box post-processor not found: %s"
,
ppName
)
}
config
:=
map
[
string
]
string
{
"output"
:
p
.
config
.
OutputPath
}
if
err
:=
pp
.
Configure
(
config
);
err
!=
nil
{
if
err
:=
pp
.
Configure
(
p
.
rawConfigs
...
);
err
!=
nil
{
return
nil
,
false
,
err
}
}
...
...
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