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
a3e4554a
Commit
a3e4554a
authored
Oct 06, 2014
by
Kent Holloway
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'upstream/master'
parents
9e2d0af5
2aa5a198
Changes
16
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
233 additions
and
283 deletions
+233
-283
CHANGELOG.md
CHANGELOG.md
+7
-0
builder/parallels/common/driver.go
builder/parallels/common/driver.go
+3
-0
builder/parallels/common/driver_9.go
builder/parallels/common/driver_9.go
+23
-0
builder/parallels/common/driver_mock.go
builder/parallels/common/driver_mock.go
+13
-0
builder/parallels/common/step_attach_floppy.go
builder/parallels/common/step_attach_floppy.go
+3
-4
builder/parallels/common/step_attach_parallels_tools.go
builder/parallels/common/step_attach_parallels_tools.go
+11
-17
builder/parallels/common/step_remove_devices.go
builder/parallels/common/step_remove_devices.go
+0
-67
builder/parallels/common/step_remove_devices_test.go
builder/parallels/common/step_remove_devices_test.go
+0
-93
builder/parallels/iso/builder.go
builder/parallels/iso/builder.go
+0
-1
builder/parallels/iso/step_attach_iso.go
builder/parallels/iso/step_attach_iso.go
+57
-16
builder/parallels/iso/step_create_disk.go
builder/parallels/iso/step_create_disk.go
+1
-1
builder/parallels/iso/step_create_vm.go
builder/parallels/iso/step_create_vm.go
+1
-0
builder/parallels/pvm/builder.go
builder/parallels/pvm/builder.go
+0
-1
website/Gemfile
website/Gemfile
+9
-8
website/Gemfile.lock
website/Gemfile.lock
+105
-71
website/counter.txt
website/counter.txt
+0
-4
No files found.
CHANGELOG.md
View file @
a3e4554a
## 0.7.2 (unreleased)
## 0.7.2 (unreleased)
FEATURES:
*
builder/parallels: Don't depend on _prl-utils_ [GH-1499]
BUG FIXES:
BUG FIXES:
*
builder/vmware-vmx: Fix issue with order of boot command support [GH-1492]
*
builder/vmware-vmx: Fix issue with order of boot command support [GH-1492]
*
builder/parallels: Ignore 'The fdd0 device does not exist' [GH-1501]
*
builder/parallels: Rely on Cleanup functions to detach devices [GH-1502]
*
builder/parallels: Create VM without hdd and then add it later [GH-1548]
## 0.7.1 (September 10, 2014)
## 0.7.1 (September 10, 2014)
...
...
builder/parallels/common/driver.go
View file @
a3e4554a
...
@@ -15,6 +15,9 @@ import (
...
@@ -15,6 +15,9 @@ import (
// versions out of the builder steps, so sometimes the methods are
// versions out of the builder steps, so sometimes the methods are
// extremely specific.
// extremely specific.
type
Driver
interface
{
type
Driver
interface
{
// Adds new CD/DVD drive to the VM and returns name of this device
DeviceAddCdRom
(
string
,
string
)
(
string
,
error
)
// Import a VM
// Import a VM
Import
(
string
,
string
,
string
,
bool
)
error
Import
(
string
,
string
,
string
,
bool
)
error
...
...
builder/parallels/common/driver_9.go
View file @
a3e4554a
...
@@ -95,6 +95,29 @@ func getAppPath(bundleId string) (string, error) {
...
@@ -95,6 +95,29 @@ func getAppPath(bundleId string) (string, error) {
return
pathOutput
,
nil
return
pathOutput
,
nil
}
}
func
(
d
*
Parallels9Driver
)
DeviceAddCdRom
(
name
string
,
image
string
)
(
string
,
error
)
{
command
:=
[]
string
{
"set"
,
name
,
"--device-add"
,
"cdrom"
,
"--image"
,
image
,
}
out
,
err
:=
exec
.
Command
(
d
.
PrlctlPath
,
command
...
)
.
Output
()
if
err
!=
nil
{
return
""
,
err
}
deviceRe
:=
regexp
.
MustCompile
(
`\s+(cdrom\d+)\s+`
)
matches
:=
deviceRe
.
FindStringSubmatch
(
string
(
out
))
if
matches
==
nil
{
return
""
,
fmt
.
Errorf
(
"Could not determine cdrom device name in the output:
\n
%s"
,
string
(
out
))
}
device_name
:=
matches
[
1
]
return
device_name
,
nil
}
func
(
d
*
Parallels9Driver
)
IsRunning
(
name
string
)
(
bool
,
error
)
{
func
(
d
*
Parallels9Driver
)
IsRunning
(
name
string
)
(
bool
,
error
)
{
var
stdout
bytes
.
Buffer
var
stdout
bytes
.
Buffer
...
...
builder/parallels/common/driver_mock.go
View file @
a3e4554a
...
@@ -5,6 +5,12 @@ import "sync"
...
@@ -5,6 +5,12 @@ import "sync"
type
DriverMock
struct
{
type
DriverMock
struct
{
sync
.
Mutex
sync
.
Mutex
DeviceAddCdRomCalled
bool
DeviceAddCdRomName
string
DeviceAddCdRomImage
string
DeviceAddCdRomResult
string
DeviceAddCdRomErr
error
ImportCalled
bool
ImportCalled
bool
ImportName
string
ImportName
string
ImportSrcPath
string
ImportSrcPath
string
...
@@ -45,6 +51,13 @@ type DriverMock struct {
...
@@ -45,6 +51,13 @@ type DriverMock struct {
IpAddressError
error
IpAddressError
error
}
}
func
(
d
*
DriverMock
)
DeviceAddCdRom
(
name
string
,
image
string
)
(
string
,
error
)
{
d
.
DeviceAddCdRomCalled
=
true
d
.
DeviceAddCdRomName
=
name
d
.
DeviceAddCdRomImage
=
image
return
d
.
DeviceAddCdRomResult
,
d
.
DeviceAddCdRomErr
}
func
(
d
*
DriverMock
)
Import
(
name
,
srcPath
,
dstPath
string
,
reassignMac
bool
)
error
{
func
(
d
*
DriverMock
)
Import
(
name
,
srcPath
,
dstPath
string
,
reassignMac
bool
)
error
{
d
.
ImportCalled
=
true
d
.
ImportCalled
=
true
d
.
ImportName
=
name
d
.
ImportName
=
name
...
...
builder/parallels/common/step_attach_floppy.go
View file @
a3e4554a
...
@@ -39,11 +39,10 @@ func (s *StepAttachFloppy) Run(state multistep.StateBag) multistep.StepAction {
...
@@ -39,11 +39,10 @@ func (s *StepAttachFloppy) Run(state multistep.StateBag) multistep.StepAction {
"set"
,
vmName
,
"set"
,
vmName
,
"--device-del"
,
"fdd0"
,
"--device-del"
,
"fdd0"
,
}
}
if
err
:=
driver
.
Prlctl
(
del_command
...
);
err
!=
nil
{
// This will almost certainly fail with 'The fdd0 device does not exist.'
state
.
Put
(
"error"
,
fmt
.
Errorf
(
"Error deleting floppy: %s"
,
err
))
driver
.
Prlctl
(
del_command
...
)
}
ui
.
Say
(
"Attaching floppy disk..."
)
ui
.
Say
(
"Attaching floppy disk..."
)
// Attaching the floppy disk
// Attaching the floppy disk
add_command
:=
[]
string
{
add_command
:=
[]
string
{
"set"
,
vmName
,
"set"
,
vmName
,
...
...
builder/parallels/common/step_attach_parallels_tools.go
View file @
a3e4554a
...
@@ -17,8 +17,8 @@ import (
...
@@ -17,8 +17,8 @@ import (
// vmName string
// vmName string
//
//
// Produces:
// Produces:
// attachedToolsIso boolean
type
StepAttachParallelsTools
struct
{
type
StepAttachParallelsTools
struct
{
cdromDevice
string
ParallelsToolsMode
string
ParallelsToolsMode
string
}
}
...
@@ -37,27 +37,25 @@ func (s *StepAttachParallelsTools) Run(state multistep.StateBag) multistep.StepA
...
@@ -37,27 +37,25 @@ func (s *StepAttachParallelsTools) Run(state multistep.StateBag) multistep.StepA
parallelsToolsPath
:=
state
.
Get
(
"parallels_tools_path"
)
.
(
string
)
parallelsToolsPath
:=
state
.
Get
(
"parallels_tools_path"
)
.
(
string
)
// Attach the guest additions to the computer
// Attach the guest additions to the computer
ui
.
Say
(
"Attaching Parallels Tools ISO onto IDE controller..."
)
ui
.
Say
(
"Attaching Parallels Tools ISO to the new CD/DVD drive..."
)
command
:=
[]
string
{
"set"
,
vmName
,
cdrom
,
err
:=
driver
.
DeviceAddCdRom
(
vmName
,
parallelsToolsPath
)
"--device-add"
,
"cdrom"
,
"--image"
,
parallelsToolsPath
,
if
err
!=
nil
{
}
err
:=
fmt
.
Errorf
(
"Error attaching Parallels Tools ISO: %s"
,
err
)
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error attaching Parallels Tools: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
return
multistep
.
ActionHalt
}
}
//
Set some state so we know to remove
//
Track the device name so that we can can delete later
s
tate
.
Put
(
"attachedToolsIso"
,
true
)
s
.
cdromDevice
=
cdrom
return
multistep
.
ActionContinue
return
multistep
.
ActionContinue
}
}
func
(
s
*
StepAttachParallelsTools
)
Cleanup
(
state
multistep
.
StateBag
)
{
func
(
s
*
StepAttachParallelsTools
)
Cleanup
(
state
multistep
.
StateBag
)
{
if
_
,
ok
:=
state
.
GetOk
(
"attachedToolsIso"
);
!
ok
{
if
s
.
cdromDevice
==
""
{
return
return
}
}
...
@@ -66,14 +64,10 @@ func (s *StepAttachParallelsTools) Cleanup(state multistep.StateBag) {
...
@@ -66,14 +64,10 @@ func (s *StepAttachParallelsTools) Cleanup(state multistep.StateBag) {
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
log
.
Println
(
"Detaching Parallels Tools ISO..."
)
log
.
Println
(
"Detaching Parallels Tools ISO..."
)
cdDevice
:=
"cdrom0"
if
_
,
ok
:=
state
.
GetOk
(
"attachedIso"
);
ok
{
cdDevice
=
"cdrom1"
}
command
:=
[]
string
{
command
:=
[]
string
{
"set"
,
vmName
,
"set"
,
vmName
,
"--device-del"
,
cd
Device
,
"--device-del"
,
s
.
cdrom
Device
,
}
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
...
...
builder/parallels/common/step_remove_devices.go
deleted
100644 → 0
View file @
9e2d0af5
package
common
import
(
"fmt"
"github.com/mitchellh/multistep"
"github.com/mitchellh/packer/packer"
)
// This step removes any devices (floppy disks, ISOs, etc.) from the
// machine that we may have added.
//
// Uses:
// driver Driver
// ui packer.Ui
// vmName string
//
// Produces:
type
StepRemoveDevices
struct
{}
func
(
s
*
StepRemoveDevices
)
Run
(
state
multistep
.
StateBag
)
multistep
.
StepAction
{
driver
:=
state
.
Get
(
"driver"
)
.
(
Driver
)
ui
:=
state
.
Get
(
"ui"
)
.
(
packer
.
Ui
)
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
// Remove the attached floppy disk, if it exists
if
_
,
ok
:=
state
.
GetOk
(
"floppy_path"
);
ok
{
ui
.
Message
(
"Removing floppy drive..."
)
command
:=
[]
string
{
"set"
,
vmName
,
"--device-del"
,
"fdd0"
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error removing floppy: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
}
}
if
_
,
ok
:=
state
.
GetOk
(
"attachedIso"
);
ok
{
command
:=
[]
string
{
"set"
,
vmName
,
"--device-set"
,
"cdrom0"
,
"--device"
,
"Default CD/DVD-ROM"
,
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error detaching ISO: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
}
}
if
_
,
ok
:=
state
.
GetOk
(
"attachedToolsIso"
);
ok
{
command
:=
[]
string
{
"set"
,
vmName
,
"--device-del"
,
"cdrom1"
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error detaching ISO: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
}
}
return
multistep
.
ActionContinue
}
func
(
s
*
StepRemoveDevices
)
Cleanup
(
state
multistep
.
StateBag
)
{
}
builder/parallels/common/step_remove_devices_test.go
deleted
100644 → 0
View file @
9e2d0af5
package
common
import
(
"github.com/mitchellh/multistep"
"testing"
)
func
TestStepRemoveDevices_impl
(
t
*
testing
.
T
)
{
var
_
multistep
.
Step
=
new
(
StepRemoveDevices
)
}
func
TestStepRemoveDevices
(
t
*
testing
.
T
)
{
state
:=
testState
(
t
)
step
:=
new
(
StepRemoveDevices
)
state
.
Put
(
"vmName"
,
"foo"
)
driver
:=
state
.
Get
(
"driver"
)
.
(
*
DriverMock
)
// Test the run
if
action
:=
step
.
Run
(
state
);
action
!=
multistep
.
ActionContinue
{
t
.
Fatalf
(
"bad action: %#v"
,
action
)
}
if
_
,
ok
:=
state
.
GetOk
(
"error"
);
ok
{
t
.
Fatal
(
"should NOT have error"
)
}
// Test that ISO was removed
if
len
(
driver
.
PrlctlCalls
)
!=
0
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
}
func
TestStepRemoveDevices_attachedIso
(
t
*
testing
.
T
)
{
state
:=
testState
(
t
)
step
:=
new
(
StepRemoveDevices
)
state
.
Put
(
"attachedIso"
,
true
)
state
.
Put
(
"vmName"
,
"foo"
)
driver
:=
state
.
Get
(
"driver"
)
.
(
*
DriverMock
)
// Test the run
if
action
:=
step
.
Run
(
state
);
action
!=
multistep
.
ActionContinue
{
t
.
Fatalf
(
"bad action: %#v"
,
action
)
}
if
_
,
ok
:=
state
.
GetOk
(
"error"
);
ok
{
t
.
Fatal
(
"should NOT have error"
)
}
// Test that ISO was detached
if
len
(
driver
.
PrlctlCalls
)
!=
1
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
if
driver
.
PrlctlCalls
[
0
][
2
]
!=
"--device-set"
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
if
driver
.
PrlctlCalls
[
0
][
3
]
!=
"cdrom0"
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
if
driver
.
PrlctlCalls
[
0
][
5
]
!=
"Default CD/DVD-ROM"
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
}
func
TestStepRemoveDevices_floppyPath
(
t
*
testing
.
T
)
{
state
:=
testState
(
t
)
step
:=
new
(
StepRemoveDevices
)
state
.
Put
(
"floppy_path"
,
"foo"
)
state
.
Put
(
"vmName"
,
"foo"
)
driver
:=
state
.
Get
(
"driver"
)
.
(
*
DriverMock
)
// Test the run
if
action
:=
step
.
Run
(
state
);
action
!=
multistep
.
ActionContinue
{
t
.
Fatalf
(
"bad action: %#v"
,
action
)
}
if
_
,
ok
:=
state
.
GetOk
(
"error"
);
ok
{
t
.
Fatal
(
"should NOT have error"
)
}
// Test that both were removed
if
len
(
driver
.
PrlctlCalls
)
!=
1
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
if
driver
.
PrlctlCalls
[
0
][
2
]
!=
"--device-del"
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
if
driver
.
PrlctlCalls
[
0
][
3
]
!=
"fdd0"
{
t
.
Fatalf
(
"bad: %#v"
,
driver
.
PrlctlCalls
)
}
}
builder/parallels/iso/builder.go
View file @
a3e4554a
...
@@ -294,7 +294,6 @@ func (b *Builder) Run(ui packer.Ui, hook packer.Hook, cache packer.Cache) (packe
...
@@ -294,7 +294,6 @@ func (b *Builder) Run(ui packer.Ui, hook packer.Hook, cache packer.Cache) (packe
Command
:
b
.
config
.
ShutdownCommand
,
Command
:
b
.
config
.
ShutdownCommand
,
Timeout
:
b
.
config
.
ShutdownTimeout
,
Timeout
:
b
.
config
.
ShutdownTimeout
,
},
},
new
(
parallelscommon
.
StepRemoveDevices
),
}
}
// Setup the state bag
// Setup the state bag
...
...
builder/parallels/iso/step_attach_iso.go
View file @
a3e4554a
...
@@ -11,10 +11,14 @@ import (
...
@@ -11,10 +11,14 @@ import (
// This step attaches the ISO to the virtual machine.
// This step attaches the ISO to the virtual machine.
//
//
// Uses:
// Uses:
// driver Driver
// isoPath string
// ui packer.Ui
// vmName string
//
//
// Produces:
// Produces:
type
stepAttachISO
struct
{
type
stepAttachISO
struct
{
diskPath
string
cdromDevice
string
}
}
func
(
s
*
stepAttachISO
)
Run
(
state
multistep
.
StateBag
)
multistep
.
StepAction
{
func
(
s
*
stepAttachISO
)
Run
(
state
multistep
.
StateBag
)
multistep
.
StepAction
{
...
@@ -24,41 +28,78 @@ func (s *stepAttachISO) Run(state multistep.StateBag) multistep.StepAction {
...
@@ -24,41 +28,78 @@ func (s *stepAttachISO) Run(state multistep.StateBag) multistep.StepAction {
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
// Attach the disk to the controller
// Attach the disk to the controller
ui
.
Say
(
"Attaching ISO onto IDE controller..."
)
ui
.
Say
(
"Attaching ISO to the new CD/DVD drive..."
)
cdrom
,
err
:=
driver
.
DeviceAddCdRom
(
vmName
,
isoPath
)
if
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error attaching ISO: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
}
// Set new boot order
ui
.
Say
(
"Setting the boot order..."
)
command
:=
[]
string
{
command
:=
[]
string
{
"set"
,
vmName
,
"set"
,
vmName
,
"--device-set"
,
"cdrom0"
,
"--device-bootorder"
,
fmt
.
Sprintf
(
"hdd0 %s cdrom0 net0"
,
cdrom
),
"--image"
,
isoPath
,
"--enable"
,
"--connect"
,
}
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error
attaching ISO
: %s"
,
err
)
err
:=
fmt
.
Errorf
(
"Error
setting the boot order
: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
return
multistep
.
ActionHalt
}
}
// Set some state so we know to remove
// Disable 'cdrom0' device
state
.
Put
(
"attachedIso"
,
true
)
ui
.
Say
(
"Disabling default CD/DVD drive..."
)
command
=
[]
string
{
"set"
,
vmName
,
"--device-set"
,
"cdrom0"
,
"--disable"
,
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
err
:=
fmt
.
Errorf
(
"Error disabling default CD/DVD drive: %s"
,
err
)
state
.
Put
(
"error"
,
err
)
ui
.
Error
(
err
.
Error
())
return
multistep
.
ActionHalt
}
// Track the device name so that we can can delete later
s
.
cdromDevice
=
cdrom
return
multistep
.
ActionContinue
return
multistep
.
ActionContinue
}
}
func
(
s
*
stepAttachISO
)
Cleanup
(
state
multistep
.
StateBag
)
{
func
(
s
*
stepAttachISO
)
Cleanup
(
state
multistep
.
StateBag
)
{
if
_
,
ok
:=
state
.
GetOk
(
"attachedIso"
);
!
ok
{
return
}
driver
:=
state
.
Get
(
"driver"
)
.
(
parallelscommon
.
Driver
)
driver
:=
state
.
Get
(
"driver"
)
.
(
parallelscommon
.
Driver
)
ui
:=
state
.
Get
(
"ui"
)
.
(
packer
.
Ui
)
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
vmName
:=
state
.
Get
(
"vmName"
)
.
(
string
)
// Enable 'cdrom0' device back
log
.
Println
(
"Enabling default CD/DVD drive..."
)
command
:=
[]
string
{
command
:=
[]
string
{
"set"
,
vmName
,
"set"
,
vmName
,
"--device-set"
,
"cdrom0"
,
"--device-set"
,
"cdrom0"
,
"--enable"
,
"--enable"
,
"--disconnect"
,
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
ui
.
Error
(
fmt
.
Sprintf
(
"Error enabling default CD/DVD drive: %s"
,
err
))
}
// Detach ISO
if
s
.
cdromDevice
==
""
{
return
}
}
// Remove the ISO, ignore errors
log
.
Println
(
"Detaching ISO..."
)
log
.
Println
(
"Detaching ISO..."
)
driver
.
Prlctl
(
command
...
)
command
=
[]
string
{
"set"
,
vmName
,
"--device-del"
,
s
.
cdromDevice
,
}
if
err
:=
driver
.
Prlctl
(
command
...
);
err
!=
nil
{
ui
.
Error
(
fmt
.
Sprintf
(
"Error detaching ISO: %s"
,
err
))
}
}
}
builder/parallels/iso/step_create_disk.go
View file @
a3e4554a
...
@@ -20,7 +20,7 @@ func (s *stepCreateDisk) Run(state multistep.StateBag) multistep.StepAction {
...
@@ -20,7 +20,7 @@ func (s *stepCreateDisk) Run(state multistep.StateBag) multistep.StepAction {
command
:=
[]
string
{
command
:=
[]
string
{
"set"
,
vmName
,
"set"
,
vmName
,
"--device-
set"
,
"hdd0
"
,
"--device-
add"
,
"hdd
"
,
"--size"
,
strconv
.
FormatUint
(
uint64
(
config
.
DiskSize
),
10
),
"--size"
,
strconv
.
FormatUint
(
uint64
(
config
.
DiskSize
),
10
),
"--iface"
,
config
.
HardDriveInterface
,
"--iface"
,
config
.
HardDriveInterface
,
}
}
...
...
builder/parallels/iso/step_create_vm.go
View file @
a3e4554a
...
@@ -29,6 +29,7 @@ func (s *stepCreateVM) Run(state multistep.StateBag) multistep.StepAction {
...
@@ -29,6 +29,7 @@ func (s *stepCreateVM) Run(state multistep.StateBag) multistep.StepAction {
"--distribution"
,
config
.
GuestOSType
,
"--distribution"
,
config
.
GuestOSType
,
"--dst"
,
config
.
OutputDir
,
"--dst"
,
config
.
OutputDir
,
"--vmtype"
,
"vm"
,
"--vmtype"
,
"vm"
,
"--no-hdd"
,
}
}
commands
[
1
]
=
[]
string
{
"set"
,
name
,
"--cpus"
,
"1"
}
commands
[
1
]
=
[]
string
{
"set"
,
name
,
"--cpus"
,
"1"
}
commands
[
2
]
=
[]
string
{
"set"
,
name
,
"--memsize"
,
"512"
}
commands
[
2
]
=
[]
string
{
"set"
,
name
,
"--memsize"
,
"512"
}
...
...
builder/parallels/pvm/builder.go
View file @
a3e4554a
...
@@ -99,7 +99,6 @@ func (b *Builder) Run(ui packer.Ui, hook packer.Hook, cache packer.Cache) (packe
...
@@ -99,7 +99,6 @@ func (b *Builder) Run(ui packer.Ui, hook packer.Hook, cache packer.Cache) (packe
Command
:
b
.
config
.
ShutdownCommand
,
Command
:
b
.
config
.
ShutdownCommand
,
Timeout
:
b
.
config
.
ShutdownTimeout
,
Timeout
:
b
.
config
.
ShutdownTimeout
,
},
},
new
(
parallelscommon
.
StepRemoveDevices
),
}
}
// Run the steps.
// Run the steps.
...
...
website/Gemfile
View file @
a3e4554a
source
'https://rubygems.org'
source
"https://rubygems.org"
gem
"middleman"
,
"~> 3.1.5"
gem
"less"
,
"~> 2.6"
gem
"middleman-minify-html"
,
"~> 3.1.1"
gem
"middleman"
,
"~> 3.3"
gem
"rack-contrib"
,
"~> 1.1.0"
gem
"middleman-minify-html"
,
"~> 3.4"
gem
"redcarpet"
,
"~> 3.0.0"
gem
"rack-contrib"
,
"~> 1.1"
gem
"therubyracer"
,
"~> 0.12.0"
gem
"redcarpet"
,
"~> 3.1"
gem
"thin"
,
"~> 1.5.0"
gem
"therubyracer"
,
"~> 0.12"
gem
"thin"
,
"~> 1.6"
group
:development
do
group
:development
do
gem
"highline"
,
"~> 1.6
.15
"
gem
"highline"
,
"~> 1.6"
end
end
website/Gemfile.lock
View file @
a3e4554a
GEM
GEM
remote: https://rubygems.org/
remote: https://rubygems.org/
specs:
specs:
activesupport (3.2.15)
activesupport (4.1.6)
i18n (~> 0.6, >= 0.6.4)
i18n (~> 0.6, >= 0.6.9)
multi_json (~> 1.0)
json (~> 1.7, >= 1.7.7)
chunky_png (1.2.9)
minitest (~> 5.1)
coffee-script (2.2.0)
thread_safe (~> 0.1)
tzinfo (~> 1.1)
celluloid (0.16.0)
timers (~> 4.0.0)
chunky_png (1.3.1)
coffee-script (2.3.0)
coffee-script-source
coffee-script-source
execjs
execjs
coffee-script-source (1.6.3)
coffee-script-source (1.8.0)
compass (0.12.2)
commonjs (0.2.7)
compass (1.0.1)
chunky_png (~> 1.2)
chunky_png (~> 1.2)
fssm (>= 0.2.7)
compass-core (~> 1.0.1)
sass (~> 3.1)
compass-import-once (~> 1.0.5)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
sass (>= 3.3.13, < 3.5)
compass-core (1.0.1)
multi_json (~> 1.0)
sass (>= 3.3.0, < 3.5)
compass-import-once (1.0.5)
sass (>= 3.2, < 3.5)
daemons (1.1.9)
daemons (1.1.9)
erubis (2.7.0)
eventmachine (1.0.3)
eventmachine (1.0.3)
execjs (1.4.0)
execjs (2.2.1)
multi_json (~> 1.0)
ffi (1.9.5)
ffi (1.9.0)
haml (4.0.5)
fssm (0.2.10)
haml (4.0.3)
tilt
tilt
highline (1.6.2
0
)
highline (1.6.2
1
)
hike (1.2.3)
hike (1.2.3)
i18n (0.6.5)
hitimes (1.2.2)
kramdown (1.2.0)
hooks (0.4.0)
libv8 (3.16.14.3)
uber (~> 0.0.4)
listen (1.3.1)
htmlcompressor (0.1.2)
i18n (0.6.11)
json (1.8.1)
kramdown (1.4.2)
less (2.6.0)
commonjs (~> 0.2.7)
libv8 (3.16.14.7)
listen (2.7.11)
celluloid (>= 0.15.2)
rb-fsevent (>= 0.9.3)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
rb-inotify (>= 0.9)
rb-kqueue (>= 0.2
)
middleman (3.3.6
)
middleman (3.1.6
)
coffee-script (~> 2.2
)
co
ffee-script (~> 2.2
.0)
co
mpass (>= 1.0.0, < 2.0
.0)
compass
(>= 0.12.2
)
compass
-import-once (= 1.0.5
)
execjs (~>
1.4
.0)
execjs (~>
2
.0)
haml (>=
3.1.6
)
haml (>=
4.0.5
)
kramdown (~> 1.2)
kramdown (~> 1.2)
middleman-core (= 3.1.6)
middleman-core (= 3.3.6)
middleman-more (= 3.1.6)
middleman-sprockets (>= 3.1.2)
middleman-sprockets (>= 3.1.2)
sass (>= 3.
1.2
0)
sass (>= 3.
4.0, < 4.
0)
uglifier (~> 2.
1.0
)
uglifier (~> 2.
5
)
middleman-core (3.
1
.6)
middleman-core (3.
3
.6)
activesupport (~>
3.2.6
)
activesupport (~>
4.1.0
)
bundler (~> 1.1)
bundler (~> 1.1)
i18n (~> 0.6.1)
erubis
listen (~> 1.1)
hooks (~> 0.3)
rack (>= 1.4.5)
i18n (~> 0.6.9)
rack-test (~> 0.6.1)
listen (>= 2.7.9, < 3.0)
padrino-helpers (~> 0.12.3)
rack (>= 1.4.5, < 2.0)
rack-test (~> 0.6.2)
thor (>= 0.15.2, < 2.0)
thor (>= 0.15.2, < 2.0)
tilt (~> 1.3.6)
tilt (~> 1.4.1, < 2.0)
middleman-minify-html (3.1.1)
middleman-minify-html (3.4.0)
middleman-core (~> 3.0)
htmlcompressor (~> 0.1.0)
middleman-more (3.1.6)
middleman-core (>= 3.2)
middleman-sprockets (3.1.4)
middleman-sprockets (3.3.10)
middleman-core (>= 3.0.14)
middleman-core (~> 3.3)
middleman-more (>= 3.0.14)
sprockets (~> 2.12.1)
sprockets (~> 2.1)
sprockets-helpers (~> 1.1.0)
sprockets-helpers (~> 1.0.0)
sprockets-sass (~> 1.2.0)
sprockets-sass (~> 1.0.0)
minitest (5.4.2)
multi_json (1.8.2)
multi_json (1.10.1)
padrino-helpers (0.12.3)
i18n (~> 0.6, >= 0.6.7)
padrino-support (= 0.12.3)
tilt (~> 1.4.1)
padrino-support (0.12.3)
activesupport (>= 3.1)
rack (1.5.2)
rack (1.5.2)
rack-contrib (1.1.0)
rack-contrib (1.1.0)
rack (>= 0.9.1)
rack (>= 0.9.1)
rack-test (0.6.2)
rack-test (0.6.2)
rack (>= 1.0)
rack (>= 1.0)
rb-fsevent (0.9.3)
rb-fsevent (0.9.4)
rb-inotify (0.9.2)
rb-inotify (0.9.5)
ffi (>= 0.5.0)
rb-kqueue (0.2.0)
ffi (>= 0.5.0)
ffi (>= 0.5.0)
redcarpet (3.
0.0
)
redcarpet (3.
1.2
)
ref (1.0.5)
ref (1.0.5)
sass (3.
2.12
)
sass (3.
4.5
)
sprockets (2.1
0.0
)
sprockets (2.1
2.2
)
hike (~> 1.2)
hike (~> 1.2)
multi_json (~> 1.0)
multi_json (~> 1.0)
rack (~> 1.0)
rack (~> 1.0)
tilt (~> 1.1, != 1.3.0)
tilt (~> 1.1, != 1.3.0)
sprockets-helpers (1.
0.1
)
sprockets-helpers (1.
1.0
)
sprockets (~> 2.0)
sprockets (~> 2.0)
sprockets-sass (1.
0.2
)
sprockets-sass (1.
2.0
)
sprockets (~> 2.0)
sprockets (~> 2.0)
tilt (~> 1.1)
tilt (~> 1.1)
therubyracer (0.12.
0
)
therubyracer (0.12.
1
)
libv8 (~> 3.16.14.0)
libv8 (~> 3.16.14.0)
ref
ref
thin (1.5.1)
thin (1.6.3)
daemons (>= 1.0.9)
daemons (~> 1.0, >= 1.0.9)
eventmachine (>= 0.12.6)
eventmachine (~> 1.0)
rack (>= 1.0.0)
rack (~> 1.0)
thor (0.18.1)
thor (0.19.1)
tilt (1.3.7)
thread_safe (0.3.4)
uglifier (2.1.2)
tilt (1.4.1)
timers (4.0.1)
hitimes
tzinfo (1.2.2)
thread_safe (~> 0.1)
uber (0.0.8)
uglifier (2.5.3)
execjs (>= 0.3.0)
execjs (>= 0.3.0)
multi_json (~> 1.0, >= 1.0.2
)
json (>= 1.8.0
)
PLATFORMS
PLATFORMS
ruby
ruby
DEPENDENCIES
DEPENDENCIES
highline (~> 1.6.15)
highline (~> 1.6)
middleman (~> 3.1.5)
less (~> 2.6)
middleman-minify-html (~> 3.1.1)
middleman (~> 3.3)
rack-contrib (~> 1.1.0)
middleman-minify-html (~> 3.4)
redcarpet (~> 3.0.0)
rack-contrib (~> 1.1)
therubyracer (~> 0.12.0)
redcarpet (~> 3.1)
thin (~> 1.5.0)
therubyracer (~> 0.12)
thin (~> 1.6)
website/counter.txt
deleted
100644 → 0
View file @
9e2d0af5
Just update this if you want to force a website push and it isn't
working:
1
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