Marcin Bojko
d4ff29f6c5
hyper-v fix when management interface is not part of virtual switch
...
2
formatting fix
2019-08-22 07:54:50 +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
Megan Marsh
cd3b39ad17
commit generated code
2019-08-12 15:55:43 -07:00
Stephen Fox
a6830f8348
Move 'ui' variable closer to invocation.
2019-07-31 14:08:40 -04:00
Stephen Fox
e362d2f3ee
Use 'log.Printf()' for StepDownload debug instead of 'ui.Say()'.
2019-07-31 14:02:57 -04:00
Megan Marsh
90c5da40f2
implement abort logic and printing for the askstep implementation as well
2019-07-26 12:24:03 -07:00
Megan Marsh
54034689ef
On abort, return gracefully rather than exiting so that the subprocess doesn't unexpectedly disconnect from the parent and cause a confusing EOF error in the logs
2019-07-25 16:32:16 -07:00
Christian Muehlhaeuser
216afbaa8b
Fixed various typos
...
Just a bunch of nit-picky typo fixes.
2019-07-25 06:49:51 +02:00
Megan Marsh
e9549d2688
add test for local fs download
2019-07-22 09:17:48 -07:00
Megan Marsh
197a283b5e
actually check for filepath being present
2019-07-19 10:35:50 -07:00
Megan Marsh
64f16474f8
fix double slash conundrum
2019-07-19 10:16:40 -07:00
WilliamB
aef77771c0
Correct HTTPIP == FALSE on HyperV builder
2019-07-17 03:41:41 -05:00
Megan Marsh
d6d4eb2087
fix some tests and some config behavior to prevent null dereference errors and incorrect precedence between iso checksum and iso checksum url
2019-06-28 15:29:39 -07:00
Megan Marsh
998ef4053f
parse checksum file so that we can use the checksums inside in the vmware-esxi builder stepuploadiso
2019-06-28 14:35:43 -07:00
Megan Marsh
88d589cc88
enable smb share double backslash pathing too
2019-06-26 13:43:05 -07:00
Megan Marsh
12471a8b06
use file getter for smb shares
2019-06-26 13:21:49 -07:00
Adrien Delorme
735b34e01f
Document the virtualbox-iso builder using partials
2019-06-19 17:37:22 +02:00
Adrien Delorme
4c1abf828c
Merge branch 'master' into scrape_doc_to_builder_struct_config
2019-06-19 11:21:06 +02:00
Megan Marsh
8d25cc578f
Merge pull request #7746 from hashicorp/fix_7671
...
Abort hyperv build if there's a name collision
2019-06-14 10:58:22 -07:00
Adrien Delorme
daa9f9d34e
Merge remote-tracking branch 'origin/master' into scrape_doc_to_builder_struct_config
2019-06-14 15:17:56 +02:00
Adrien Delorme
425ad1c67e
generate Shutdown command docs from strutc & use in hyperv
2019-06-14 12:43:31 +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
926c8bbaa6
refactor ShutdownConfig into a single struct
2019-06-14 12:17:28 +02:00
Adrien Delorme
24fad50b00
hyperv-iso: document boot config, http & floppy from partials
2019-06-14 12:17:27 +02:00
Adrien Delorme
3bb8c92902
qemu: document boot command from struct
2019-06-14 12:17:27 +02:00
Adrien Delorme
b48d22b43b
qemu: document FloppyConfig from struct
2019-06-14 11:52:38 +02:00
Adrien Delorme
3b66cac617
document HTTPConfig from struct
2019-06-14 11:52:38 +02:00
Megan Marsh
2e821da84b
check to make sure a vm-name isn't already in use before trying to launch a vm with said name.
2019-06-13 14:09:45 -07:00
Adrien Delorme
dbfadc0eea
generate struct markdown from common/iso_config.go
2019-06-12 16:02:49 +02:00
Adrien Delorme
20a152d4aa
add comments to common/iso_config.go from docs
2019-06-12 16:02:02 +02:00
Adrien Delorme
ca33f8bc5c
Revert "Backoff.Linear: panic when InitialBackoff > MaxBackoff"
...
This reverts commit 39cfacd5fa6a7317a4c9f8658a1753812cc48bc0.
2019-06-11 12:53:06 +02:00
Adrien Delorme
39cfacd5fa
Backoff.Linear: panic when InitialBackoff > MaxBackoff
...
this probably means there's a configuration issue.
Since this struct is mainly set manually from code, I think it is okay to panic here.
2019-06-11 12:41:21 +02:00
Adrien Delorme
36e4eaff99
document retry.Backoff better
2019-06-11 12:20:00 +02:00
Radek Simko
8519da6ce9
common/net: Cleanup cache of used port after closing
2019-05-06 22:11:52 +01:00
Adrien Delorme
b329073e54
remove trying port log as retry code will show errors
...
less logs !
2019-05-01 13:04:51 +02:00
Adrien Delorme
38f789eedc
add error types to test for
2019-05-01 13:01:25 +02:00
Adrien Delorme
14f2d1c132
ListenRangeConfig:Listen: use the retry pkg to wait a bit in between opens
2019-05-01 12:27:32 +02:00
Adrien Delorme
e14d1b8b0b
add a timeout trying to open a random port
2019-05-01 12:01:34 +02:00
Adrien Delorme
2fd7adffc4
add tests for ListenRangeConfig.Listen
2019-05-01 11:46:48 +02:00
Adrien Delorme
d9e5145de9
Shadow the flock pkg & add a noop filelock so that at least the solaris binary can be built
...
Without this the following error occurs:
$ GOOS=solaris go build .
# github.com/hashicorp/packer/vendor/github.com/gofrs/flock
vendor/github.com/gofrs/flock/flock_unix.go:28:22: undefined: syscall.LOCK_EX
vendor/github.com/gofrs/flock/flock_unix.go:39:22: undefined: syscall.LOCK_SH
vendor/github.com/gofrs/flock/flock_unix.go:56:12: undefined: syscall.Flock
vendor/github.com/gofrs/flock/flock_unix.go:66:12: undefined: syscall.Flock
vendor/github.com/gofrs/flock/flock_unix.go:96:12: undefined: syscall.Flock
vendor/github.com/gofrs/flock/flock_unix.go:96:42: undefined: syscall.LOCK_UN
vendor/github.com/gofrs/flock/flock_unix.go:118:21: undefined: syscall.LOCK_EX
vendor/github.com/gofrs/flock/flock_unix.go:130:21: undefined: syscall.LOCK_SH
vendor/github.com/gofrs/flock/flock_unix.go:149:9: undefined: syscall.Flock
vendor/github.com/gofrs/flock/flock_unix.go:149:44: undefined: syscall.LOCK_NB
vendor/github.com/gofrs/flock/flock_unix.go:149:44: too many errors
2019-04-30 16:01:23 +02:00
Adrien Delorme
5d9d43c01d
add tests for ListenRangeConfig.Listen
2019-04-30 15:42:59 +02:00
Adrien Delorme
fd63ec9a6c
ListenRangeConfig.Listen: move trying port log after fslock trylock for less logs
2019-04-30 15:35:22 +02:00
Adrien Delorme
79ae62801f
ListenRangeConfig: default network ( protocol ) to tcp
2019-04-30 14:55:38 +02:00
Adrien Delorme
65be2be38b
step_download: force copy of local files only on windows
2019-04-29 09:39:21 +02:00
Adrien Delorme
200e26ea85
Step download: always copy local files
...
instead of symlinking to fix #7534 . The longer term fix for this would be to change the go-getter so that it can leave the source file where it is & tell us where it is.
We will do this when the right time comes.
2019-04-26 10:35:18 +02:00
Adrien Delorme
9f1136db77
retry: encapsulate & return the last seen error in a RetryExhaustedError
2019-04-24 14:19:23 +02:00
Megan Marsh
e69d95eb37
when retries were exhausted in the retry Run, we were returning nil instead of an error.
2019-04-23 13:48:30 -07:00
Adrien Delorme
5f0259fe89
step download: don't fail when checksum_type is not set
2019-04-16 18:09:54 +02:00
Adrien Delorme
4dc12701d3
step_download: display clearer error messages, also when the checksum is not set
...
Usually the builder validation should error when the checksum is empty, but for the virtualbox-ovf builder this is not validated. Which is something I didn't see when refactoring for go-getter incorporation/refactor.
2019-04-15 14:34:09 +02:00
Megan Marsh
78cf1405ab
Merge pull request #7480 from BobSilent/fix-hyperv-multiple-hostadapter-same-switch
...
Fixes "Host IP for the HyperV machine: False" if more than one VMNetworkAdapter is found
2019-04-12 14:06:46 -07:00