490 Commits

Author SHA1 Message Date
Lars Lehtonen
4a3a011310
builder/virtualbox/vm: fix dropped error 2019-10-01 15:54:28 -07:00
Adrien Delorme
3fe9d52e3f Merge remote-tracking branch 'origin/master' into scrape_doc_to_builder_struct_config 2019-09-20 11:15:44 +02:00
allinwait
171c2a9a07 add the floppy label option 2019-09-12 12:25:22 +00:00
Brian Fox
5b6dcb0c94 fix(virtualbox) LoadSnapshots should succeed even if VM has no snapshots 2019-09-12 10:51:12 +02:00
Adrien Delorme
597a3e323b Merge remote-tracking branch 'origin/master' into scrape_doc_to_builder_struct_config 2019-09-10 13:20:07 +02:00
Adrien Delorme
350aa54274 Update step_shutdown_test.go
bump test duration
2019-09-10 13:07:30 +02:00
Adrien Delorme
4cb7c30987 Merge remote-tracking branch 'origin/master' into scrape_doc_to_builder_struct_config 2019-08-21 16:44:23 +02:00
Thomas Meckel
01edafb49f Cleaned up golint warnings 2019-08-19 21:36:43 +02:00
Thomas Meckel
92501cd344 target_snapshot is not optional as described in the documentation 2019-08-19 21:36:43 +02:00
Megan Marsh
06bef2844b
Merge pull request #7996 from hashicorp/fix_7925
dont bother with a targetpath for the vbox additions; use a hash like…
2019-08-19 09:45:38 -07:00
Brian Fox
47c027e5c8 Remove check/requirement for target_snapshot 2019-08-19 11:25:17 +02:00
Megan Marsh
02399f32f6 dont bother with a targetpath for the vbox additions; use a hash like everything else 2019-08-15 15:10:25 -07:00
Thomas Meckel
822b72bd14 Added force_delete_snapshot configuration item and the corresponding checks 2019-07-26 12:34:28 +02:00
Thomas Meckel
e7583de847 StepCreateSnapshot.Run() will stop and create an error if the virtual machine is still running
Removed left over code from StepCreateSnapshot.Cleanup()
2019-07-26 12:34:27 +02:00
Thomas Meckel
d9b8623f64 StepShutdown now always waits for the shutdown of the virtual machine to complete, not only if a shutdown command is specified 2019-07-26 12:34:27 +02:00
Thomas Meckel
b873876670 Added test TestSnapshot_EnsureParents
No using asserts NotNil and Nil
2019-07-26 12:34:27 +02:00
Thomas Meckel
6fd0b3e83e Fixed a bug in ParseSnapshotData
Added fuction GetSnapshots
2019-07-26 12:34:26 +02:00
Thomas Meckel
225a140055 Applied correct source format (got fmt) to builder\virtualbox\common\driver_mock.go 2019-07-26 12:34:26 +02:00
Thomas Meckel
51e5ae69db Corrected method signatures in builder\virtualbox\common\driver_mock.go 2019-07-26 12:34:26 +02:00
Thomas Meckel
ab6a163ff2 Added missing newline at end of builder\virtualbox\common\driver_mock.go 2019-07-26 12:34:25 +02:00
Thomas Meckel
e9b5332e99 Added missing functions to builder\virtualbox\common\driver_mock.go 2019-07-26 12:34:25 +02:00
Thomas Meckel
fd5a2db58f Removed commented (obsolete) code from builder\virtualbox\common\driver_4_2.go 2019-07-26 12:34:25 +02:00
Thomas Meckel
7d3c84e5f9 Changed VirtualBox VM builder according to current builder interface 2019-07-26 12:29:48 +02:00
Thomas Meckel
2ef911f6f0 Fixed bugs in snapshot and builder code 2019-07-26 12:29:47 +02:00
Thomas Meckel
ebd2780e5d implemented first unit tests for snapshot.go 2019-07-26 12:29:46 +02:00
Thomas Meckel
f1f7c4e10c * added function ParseSnapshotData to parse a string representation of a VBox snapshot tree
* fixed bugs
2019-07-26 12:29:46 +02:00
Thomas Meckel
45e2095ae3 Moved parsing of tree string representation to new function in snapshot.go 2019-07-26 12:29:45 +02:00
Thomas Meckel
092e32fe9e First version of reworked snapshot implementation 2019-07-26 12:29:45 +02:00
Thomas Meckel
a6074894f1 Defined struct and first function for enhanced snapshot handling 2019-07-26 12:29:45 +02:00
Thomas Meckel
d3202497ae First working version of virtualbox/vm builder 2019-07-26 12:29:44 +02:00
Thomas Meckel
2a531f8ad6 Merged changes from local branch 2019-07-26 12:29:44 +02:00
Adrien Delorme
74f0d56cfc virtualbox merge vbpx manage configs 2019-06-19 17:07:23 +02:00
Adrien Delorme
01eff9472a virtualbox: merge ExportOpts and ExportConfig structs 2019-06-19 16:35:15 +02:00
Adrien Delorme
9b75c0af3d WIP VB 2019-06-17 16:42:49 +02:00
Adrien Delorme
c11ef90cb6 use interpolate.NewContext() instead of testConfigTemplate(t)
because it's what's happenning there
2019-06-14 12:17:28 +02:00
Adrien Delorme
4bf6a56d71 split communitacor.SSH & communitacor.WinRM to facilitate documentation
put doc for communicator into the struct
2019-06-06 16:55:24 +02:00
Adrien Delorme
4399684372 make fmt autogenerated docs 2019-06-06 16:29:25 +02:00
Adrien Delorme
e6cbb013ba add // go:generate struct-markdown to all previously edited files 2019-06-05 16:42:18 +02:00
Adrien Delorme
f1917edd34 generate the comments for config struct of builders scraping doc website 2019-06-05 16:42:17 +02:00
Adrien Delorme
d72040f4fa move retry code into the common/retry pkg and make retry context aware 2019-04-09 17:46:38 +02:00
Adrien Delorme
f555e7a9f2 allow a provisioner to timeout
* I had to contextualise Communicator.Start and RemoteCmd.StartWithUi
NOTE: Communicator.Start starts a RemoteCmd but RemoteCmd.StartWithUi will run the cmd and wait for a return, so I renamed StartWithUi to RunWithUi so that the intent is clearer.
Ideally in the future RunWithUi will be named back to StartWithUi and the exit status or wait funcs of the command will allow to wait for a return. If you do so please read carrefully https://golang.org/pkg/os/exec/#Cmd.Stdout to avoid a deadlock
* cmd.ExitStatus to cmd.ExitStatus() is now blocking to avoid race conditions
* also had to simplify StartWithUi
2019-04-08 20:09:21 +02:00
Adrien Delorme
c4f3dccc14 rename interpolation context from ctx to ictx and contexts to ctx to avoid conflicts 2019-04-03 15:56:15 +02:00
Adrien Delorme
a4bf94dd3c change Builder to be passed a context for cancellation
we have to to give it to our hook
2019-04-03 15:55:55 +02:00
Megan Marsh
9f1a4e0fed
Merge pull request #7423 from hashicorp/lock_ports
Lock packer ports using a lock file
2019-03-26 10:35:18 -06:00
Adrien Delorme
5a6dffde9a use port as ints 2019-03-19 15:01:12 +01:00
Adrien Delorme
c214f6735b make everything a uint 2019-03-19 12:54:15 +01:00
Adrien Delorme
f67b5ff59d virtualbox StepConfigureVRDP: use common/net pkg to find open port 2019-03-19 12:54:15 +01:00
Adrien Delorme
59370986fb virtualbox StepForwardSSH: use common/net pkg to find open port 2019-03-19 12:54:15 +01:00
Vadym Haidamaka
414d0750f0 Add tests to validate 'none' communicator in the virtualbox builder 2019-03-16 18:18:29 +02:00
Vadym Haidamaka
0263503c45 Validate virtualbox_version_file and guest_additions_mode when communicator is none 2019-03-16 18:15:27 +02:00