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
02ebef90
Commit
02ebef90
authored
Dec 05, 2014
by
James Sinclair
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use an index loop as range loops over copies, not references
Fixes #1637
parent
e7f27432
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
builder/amazon/common/block_device.go
builder/amazon/common/block_device.go
+5
-5
No files found.
builder/amazon/common/block_device.go
View file @
02ebef90
...
@@ -60,12 +60,12 @@ func (b *BlockDevices) Prepare(t *packer.ConfigTemplate) []error {
...
@@ -60,12 +60,12 @@ func (b *BlockDevices) Prepare(t *packer.ConfigTemplate) []error {
var
errs
[]
error
var
errs
[]
error
for
outer
,
bds
:=
range
lists
{
for
outer
,
bds
:=
range
lists
{
for
i
,
bd
:=
range
bds
{
for
i
:=
0
;
i
<
len
(
bds
);
i
++
{
templates
:=
map
[
string
]
*
string
{
templates
:=
map
[
string
]
*
string
{
"device_name"
:
&
bd
.
DeviceName
,
"device_name"
:
&
bd
s
[
i
]
.
DeviceName
,
"snapshot_id"
:
&
bd
.
SnapshotId
,
"snapshot_id"
:
&
bd
s
[
i
]
.
SnapshotId
,
"virtual_name"
:
&
bd
.
VirtualName
,
"virtual_name"
:
&
bd
s
[
i
]
.
VirtualName
,
"volume_type"
:
&
bd
.
VolumeType
,
"volume_type"
:
&
bd
s
[
i
]
.
VolumeType
,
}
}
errs
:=
make
([]
error
,
0
)
errs
:=
make
([]
error
,
0
)
...
...
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