32 Commits

Author SHA1 Message Date
Chris Roberts
5003bb6e15 Updates to address all Ruby deprecations and warnings
This includes updates for resolving all warnings provided by Ruby
for deprecations and/or removed methods. It also enables support
for Ruby 2.7 in the specification constraint as all 2.7 related
warnings are resolved with this changeset.
2020-08-10 13:05:41 -07:00
Jeff Bonhag
6efdcd2068
Merge pull request #11430 from chrisroberts/winssh-hacks
Fix issues with Windows SSH provisioner (continued...)
2020-03-11 10:39:44 -04:00
Chris Roberts
dbec9ae68c Clean specs on public key removal 2020-03-09 15:45:04 -07:00
Chris Roberts
d595c03732 Fix test coverage on windows public key cap 2020-03-09 15:07:17 -07:00
Chris Roberts
ec9d23a531 Update public key cap to use powershell 2020-03-04 15:08:03 -08:00
Jeff Bonhag
e829902e0a Add missing method to test double 2020-03-04 15:08:03 -08:00
Chris Roberts
6f707c829d Catch any StandardError exception while waiting for Windows reboot
This prevents any unexpected connection related error from breaking
the wait loop while windows reboots. If an underlying problem unrelated
to the guest is causing exceptions, the exception will still be raised
to the user, simply after the loop has exceeded the defined maximum
wait time.

Fixes #11238
2020-03-03 17:02:04 -08:00
Chris Roberts
ade5370db3 Add reboot output to guest capability 2019-02-01 15:47:02 -08:00
Brian Cain
0188d409d4
Add test for windows reboot cap 2018-11-02 16:34:57 -07:00
Brian Cain
142a6898bc
Add reboot cap for windows
This commit introduces a proper reboot cap for Windows guests. Once it
initiates a reboot on the guest, it calls out to the wait_for_reboot cap
to block on until the guest is finished rebooting.
2018-11-02 15:25:57 -07:00
Chris Roberts
48d358adcb Add winrm and upload commands 2018-10-04 13:26:41 -07:00
Brian Cain
5ebb548be9
Add test for SMB mount_shared_folder function
This commit ensures that the command that adds the smb username and
password properly quotes the password given by the user.
2018-09-18 13:38:57 -07:00
Brian Cain
f1de9821e1
Merge pull request #8099 from chrisroberts/windows/shared-folder-path
Fix virtualbox shared folders path
2018-04-10 09:16:06 -07:00
ajpaul
e602160234 update change_host_name_test to comply with reintroduction of sleep_timeout parameter 2018-03-16 13:59:23 -04:00
ajpaul
4e8062625c update unit test for change_host_name to fix failures introduced by changes to the module 2018-03-16 13:49:39 -04:00
Adam Paul
0dc3798908 update unit test to reflect changes in change_host_name.rb 2018-03-15 11:07:02 -04:00
Rui Lopes
7fac854cf3 winssh communicator: simplify the authorized_keys file modification 2017-08-21 14:42:18 -07:00
Rui Lopes
4ab0dc19b1 winssh communicator: retain the authorized_keys file acl permissions 2017-08-21 14:42:18 -07:00
Chris Roberts
1a62743bc5 Update rspec to recent version and fix deprecations 2017-08-03 17:54:07 -07:00
Chris Roberts
cef38eefd0 Add public key capability to Windows guests for winssh communicator 2017-07-07 11:26:32 -07:00
Tim Aslat
7f675d723c Update unit test to match fix 2017-05-18 16:06:27 +09:30
Chris Roberts
7f9a4b67d2 Fix virtualbox shared folders path 2016-12-13 12:09:36 -08:00
Torsten Juergeleit
754c1eebe5 fixes #6220 - adds check for communicator type and executes the mount script as encoded command via powershell from within 'sh' for communicator != winrm 2016-06-11 16:40:25 +02:00
Seth Vargo
4418efd4a4
guests/general: Use require_relative in tests 2016-06-06 12:24:07 -04:00
Richard Guin
56a6c85e7d Windows rsync needs to create folders before syncing 2015-01-28 13:07:36 -05:00
Matt Wrock
e64f84491e adding smb sync folder implementation for windows guests addressing #3699 2014-08-11 00:07:21 -07:00
Shawn Neal
911406ed4a Addressed issues with Windows guest renaming on Win7/8
Removed dependency upon netdom which is not always available on all Windows versions. This implementation that uses PowerShell and WMI should work on all OS and PowerShell versions.

Fixed another issue where host renames would always happen when the hostname was longer than 15 characters. The COMPUTERNAME environment variable only returns the first 15 characters so we no longer use that to check the current host name.
2014-06-25 12:15:01 -07:00
Shawn Neal
d4bd05883d Fixed issue 3987
Reboot the Windows guest after renaming the computer so changes take affect immediately before attempting to provision the box.

- Changed rename from wmic to netdom since netdom seems to work correctly in Windows 2008R2 and newer OSs.
- Fixed Windows guest error translations, the wrong namespace was specified in the yaml file.
2014-06-09 22:46:03 -07:00
Shawn Neal
f4b67df978 Removed unused halt timeout and check interval settings. 2014-05-01 08:00:41 -07:00
Shawn Neal
309f301a16 Added test to verify Windows symlinks to shares are fixed 2014-04-30 17:36:36 -07:00
Shawn Neal
dbe73e842f Added guest network tests for Windows guests 2014-04-22 14:03:07 -07:00
Shawn Neal
929e41aa5c Backfilled unit tests for Windows guest support
- Fixed typo in helper test
- Removed extraneous machine.config prefix from Windows guest config validation
- Added WinRM communicator unit tests
- Added Windows guest capability unit tests
2014-04-22 11:03:37 -07:00