Mikhail Zholobov
d9d081199c
action/network: Validate IP settings, show human-readable error
2018-11-02 22:29:19 +01:00
Mikhail Zholobov
a02aaa3195
action/network: Refactor the calculation of host-only adapter IP and DHCP settings
2018-11-02 22:28:49 +01:00
Chris Roberts
1ece44ca84
Remove module loading from vlan script
2018-11-02 10:42:28 -07:00
Brian Cain
54c8ebc31a
Fixes #10229 : Add timeout for changing hostname on windows
...
Prior to this commit, if Windows was slow to reboot, Vagrant would fail
to find the right IP address to upload the wait_for_reboot script to.
This commit fixes this race condition by adding a timeout to ensure that
Vagrant can retry. It also properly catches an exception in the winrm
ready? method for checking if a guest is properly ready for
communications.
2018-11-02 09:23:00 -07:00
Brian Cain
6051f3598e
Fixes #10224 : Allow validation of config while ignoring provider
...
This commit adds a new flag to the `vagrant validate` command which
allows users to completely ignore the provider block of a config file.
This is useful for when you are running `vagrant validate` in CI and
don't want to install a valid provider to check the syntax of your
Vagratnfile. When the flag is invoked, a warning will be displayed
saying that the provider block will be ignored and not validated.
2018-10-30 13:37:22 -07:00
Brian Cain
580bcaebb0
Merge pull request #10311 from briancain/DOCKER-VM-FOLDER-MOUNT
...
Deterministic host VM synced folder location for Docker provider
2018-10-24 16:19:41 -07:00
Brian Cain
a1bb7b837a
Use semicolon over ampersand to separate commands
2018-10-24 15:27:33 -07:00
Brian Cain
e8c6916ebc
Restart each interface if systemd-networkd or networkmanager is not used
...
This commit is a workaround due to how older debian and ubuntu systems
fail to properly restart networking. Instead of relying on the init
scripts or ifup/down tools to restart each interface, this commit
instead restarts each interface individually
2018-10-24 11:34:38 -07:00
Brian Cain
1761e65f26
Fixes #9763 #10300 : Fall back on ifdown/ifup tools for network restart
...
This commit adds some additional logic that falls back to using the
ifdown/ifup tools to restart networking. On Ubuntu 14.04, the init
script was designed to always fail to restart newtorking, so it needs
to use the ifdown/up tools instead. This commit will use the networking
init script as a last resort to restart networking, assuming other
commands haven't broken networking already.
https://bugs.launchpad.net/ubuntu/+source/ifupdown/+bug/1301015
2018-10-23 14:47:12 -07:00
Brian Cain
7c06950e43
Ensure true or false for automount option
2018-10-23 09:00:55 -07:00
Brian Cain
6d0dfb2690
Fixes #10016 : Add `automount` flag if specified with synced_folder
...
This commit adds a new option to virtualbox synced_folders called
`automount`, where if set to true, will supply the `--automount` flag to
virtualbox.
2018-10-22 15:45:32 -07:00
Chris Roberts
8562daf85e
Prevent overly verbose output from SSH communicator
...
If the type of error changes on retry the messages will effectively
spam the user display with alternating messages. Log each message
sent and only re-display each message once within 10 seconds.
2018-10-19 15:18:03 -07:00
Brian Cain
65651178cd
Fixes #9591 : Allow for 'default' smb_username if set
...
Prior to this commit, Vagrant would prompt for smb username and password
every time, even if only smb_username was defined. This commit changes
that by allowing a "default" username from the Vagrantfile, with the
option of overriding it.
2018-10-19 13:26:18 -07:00
Brian Cain
e54c9b22ef
Merge pull request #10301 from briancain/debian-fixup-hostname-change
...
Fixes #9763 , #10300 : Split out how hostname is set with Debian hosts
2018-10-18 08:57:29 -07:00
Brian Cain
94bb50fa7e
Add test for syncing folders with docker provider
2018-10-17 14:14:27 -07:00
Martin Jonas
238338d803
Deterministic host VM synced folder location for Docker provider to prevent broken sync after host VM shutdown
...
Fix for #10282
2018-10-17 11:28:24 -07:00
Brian Cain
15fb2b729d
Remove #Hash.compact for ruby 2.3 compatibility
2018-10-16 14:41:31 -07:00
Brian Cain
0c5d55e69c
Fixes #9763 , #10300 : Split out how hostname is set with Debian hosts
...
Prior to this commit, the hostname was set with one big bash script and
attempted to determine what tools are available. This commit changes
that by splitting out that tool check on the Vagrant side of things with
the GuestInspection class, and adds back restarting networking to get a
DHCP lease with the change rather than using `dhclient`. This pattern
matches how hostnames are set in the redhat capability.
2018-10-16 12:00:25 -07:00
Brian Cain
42c01f241c
Mark password as sensitive in logs
2018-10-12 09:07:12 -07:00
Brian Cain
adefbbaf6e
Scrub Vagrant Cloud tokens from RestClient logger
2018-10-12 09:07:12 -07:00
Brian Cain
e8115a4389
Update based on second round of feedback
2018-10-12 09:07:12 -07:00
Brian Cain
d8ec19faa8
Fixup: Update vagrant cloud command PR with feedback
2018-10-12 09:07:12 -07:00
Brian Cain
e67dac0dbb
Alias `vagrant login` command
2018-10-12 09:07:12 -07:00
Brian Cain
3c45acc35f
Continue if entity already exists with publish command
2018-10-12 09:07:12 -07:00
Brian Cain
83bd592e30
Introduce curl helper and uploader classes
...
This commit introduces a new uploader class for uploading files and
splits up some commonly used functionality between it and the downloader
class into a curl helper library.
2018-10-12 09:07:10 -07:00
Brian Cain
e70b871660
Introduce `cloud` command
...
This commit adds a new command to Vagrant called `cloud`. It handles any
and all interactions with the external service Vagrant Cloud.
2018-10-12 09:06:00 -07:00
Chris Roberts
95fad3a8e3
Merge pull request #10259 from hoatle/bugs/#10258-vagrant_ansible_local_inventory
...
@ #10258 | BUG: should not create /tmp/vagrant-ansible/inventory/vagrant_ansible_local_inventory/vagrant_ansible_local_inventory
2018-10-11 10:48:27 -07:00
Brian Cain
cc14b43a96
Ensure `tmpdir` is loaded for rsync helper class
2018-10-11 09:57:20 -07:00
Brian Cain
cb0bd89ae1
Fixes #10289 : Create proper tmp dir for ControlPath
...
Prior to this commit, when creating the ControlPath tmp dir for
socket path, Vagrant would simply rely on `rand(1000)` for making unique
dirs for rsyncing files which could result in collisions. This commit
updates that be properly using `Dir.mktmpdir` with a `vagrant-rsync-`
prefix.
2018-10-11 09:51:03 -07:00
Chris Roberts
080dd748ef
Merge pull request #10265 from chrisroberts/f-win-chktyp
...
Only configure CheckpointType if available to be configured.
2018-10-09 14:47:15 -07:00
Chris Roberts
7241bd9fda
Merge pull request #10264 from chrisroberts/f-win-autochk
...
Wrap automatic checkpoint enable to prevent inadvertent execution
2018-10-09 14:46:04 -07:00
Chris Roberts
93c2f0f497
Merge pull request #10263 from chrisroberts/e-winrm-extensions
...
Add winrm and upload commands
2018-10-09 14:42:54 -07:00
Chris Roberts
ba0f0fbcab
Default destination to basename of clean source
2018-10-08 15:29:55 -07:00
Chris Roberts
49a9ae4bd9
Remove current communicator name from error text
2018-10-08 14:30:11 -07:00
Chris Roberts
3181b5c1f9
Ensure winrm helper is loaded for command
2018-10-08 14:28:52 -07:00
Chris Roberts
d81abc1245
Fix active machine check to use common types when setting arguments
2018-10-08 14:22:32 -07:00
Chris Roberts
412290828b
Fix trailing quotes in source path
2018-10-08 14:18:30 -07:00
Brian Cain
5daa25db80
Merge pull request #10267 from briancain/ruby-trigger-option
...
Fixes #9840 : Introduce `ruby` option for trigger
2018-10-08 09:02:17 -07:00
Brian Cain
f4d618eb58
Fixes #9840 : Introduce `ruby` option for trigger
...
This commit introduces a new option to the core trigger feature: `ruby`.
It can be defined to run ruby code when the trigger is configured to
fire. If you give the ruby block an env and machine argument, the
defined ruby code can use those variables internally.
2018-10-05 12:53:41 -07:00
Chris Roberts
88469d99f7
Only configure CheckpointType if available to be configured.
2018-10-04 15:24:05 -07:00
Chris Roberts
9c1ab2bd9f
Wrap automatic checkpoint enable to prevent inadvertent execution
2018-10-04 15:16:58 -07:00
Chris Roberts
904a712838
Provide correct RDP information within configuration information
...
Dynamically generate RDP information when applicable via provider
if supported. When no RDP port is provided ignore RDP in config
and omit from output.
2018-10-04 14:41:10 -07:00
Chris Roberts
64987daf06
Merge pull request #10255 from chrisroberts/e-base-mac-vbox
...
Allow automatic mac address assignment with virtuabox provider
2018-10-04 13:38:08 -07:00
Chris Roberts
48d358adcb
Add winrm and upload commands
2018-10-04 13:26:41 -07:00
hoatle
cae2119c0f
@ #10258 | BUG: should not create /tmp/vagrant-ansible/inventory/vagrant_ansible_local_inventory/vagrant_ansible_local_inventory
2018-10-02 16:21:15 +07:00
Brian Cain
184d114374
Merge pull request #10242 from briancain/IGNORE-BOX-VAGRNANTFILE
...
Add config option `ignore_box_vagrantfile`
2018-10-01 11:07:28 -07:00
Chris Roberts
85dc0ebec9
Allow automatic mac address assignment with virtuabox provider
2018-10-01 11:05:28 -07:00
Chris Roberts
11b0d58fa0
Include communicator on call
2018-10-01 08:43:49 -07:00
Chris Roberts
1797798760
Fix module name
2018-09-28 07:59:39 -07:00
Brian Cain
424f49b919
Simplify config option to ignore box vagrantfile
2018-09-26 10:31:41 -07:00
Alex Wu
282c7341c9
add a option to ignore the vagrantfile packaged with the box
2018-09-26 10:10:45 -07:00
Brian Cain
5f56f0c8b1
Merge pull request #10223 from chrisroberts/e-rhel-nmsysd
...
Update restart logic in redhat change_host_name cap
2018-09-25 13:53:41 -07:00
Brian Cain
58ebd52f99
Add abort option to core triggers
...
This commit adds a new option `abort`, which when configured, will exit
the Vagrant process completely. If set to `true`, it will exit cleanly
with exit code 0. Otherwise, the exit code can be configured.
2018-09-25 09:40:36 -07:00
Chris Roberts
ff021fcab4
Update redhat change host name capability to support systemd
...
Update capability to use guest inspection module for determining
correct actions to execute. When systemd is in use restart the
correct active service, either NetworkManager or networkd. Default
to using the original service restart when systemd service is not
found.
2018-09-20 16:44:08 -07:00
Joe Doss
19aa9578c7
Exit 1 if we cannot set the hostname.
2018-09-20 15:28:37 -07:00
Joe Doss
c14a4a09f7
Switch if statements, check for systemctl, and switch to is-active.
2018-09-20 15:28:37 -07:00
Joe Doss
94954739b5
Simplified if statements.
2018-09-20 15:28:37 -07:00
Joe Doss
80006251f4
Add in logic to restart NetworkManager if it is enabled.
2018-09-20 15:28:36 -07:00
Brian Cain
a4d5ee6ac1
Merge pull request #10215 from briancain/FIX-SALT-PILLAR
...
Salt pillar configuration on Windows guests
2018-09-20 09:17:32 -07:00
Brian Cain
4612619dc4
Fixup docker config update
2018-09-19 10:52:59 -07:00
Oleksiy Protas
166fe374b6
More explicit logging and 'dockerfile' option support
2018-09-19 10:25:37 -07:00
Oleksiy Protas
cbc69f5158
Build from git operation for docker
2018-09-19 10:24:09 -07:00
Oleksiy Protas
de6a1794c7
Config, validation and test
2018-09-19 10:24:09 -07:00
Oleksiy Protas
8d1b5fc1c9
Docu changes for building Docker images from git
2018-09-19 10:24:05 -07:00
Brian Cain
c3c7ad4ea2
Merge pull request #10218 from briancain/fix-env-vars-puppet-windows
...
Fixes #8315 : Properly set env variables for puppet provisioner
2018-09-19 09:04:01 -07:00
John Rizzo
b7d702ab5f
Update mount_shared_folder.rb
...
This change allows special characters in the password such as ) which will cause cmdkey to fail without the quotes.
2018-09-18 13:34:32 -07:00
Brian Cain
06b3268b6f
Fixes #8315 : Properly set env variables for puppet provisioner
...
Prior to this commit, the puppet provisioner would not properly set its
environment variables, if any were configured in the Vagrantfile. This
commit separates those properly with semicolons when calling out to
puppet apply.
2018-09-18 10:09:01 -07:00
mtkennerly
5c50c50d73
Fix #8328 : Use special quote and backslash formatting for Windows when setting Salt pillar.
2018-09-17 14:20:31 -07:00
Brian Cain
9ad04ada6c
Merge pull request #9431 from blueyed/options-without-leading-space
...
salt: remove leading space with bootstrap_options
2018-09-17 11:26:54 -07:00
Brian Cain
4fd9d522f6
Merge pull request #9432 from blueyed/curl-s
...
salt: bootstrap-salt.sh: use -s with curl
2018-09-17 11:13:21 -07:00
Brian Cain
13b09bedac
( #9802 ) Allow non-windows hosts to pass along version
...
The salt bootstrap can now accept version arguments on non-windows
hosts, so this commit allows the Vagrant provisinoer to specify a
version.
2018-09-07 13:39:36 -07:00
Brian Cain
4f42da15de
Merge pull request #10171 from eigengrau/default-template
...
vagrant init: Support VAGRANT_DEFAULT_TEMPLATE
2018-09-07 11:17:46 -07:00
Brian Cain
6c8d997053
Merge pull request #10181 from chrisroberts/f-auto-checkpoints
...
Check for automatic checkpoint support before configuring
2018-09-07 10:44:26 -07:00
Chris Roberts
1f74aedeaa
Check for automatic checkpoint support before configuring
...
The AutomaticCheckpointsEnabled option may not always be available
depending on the version in use. Check for support before applying
the configured value. If automatic checkpoints are to be enabled
and support is not available, force an error.
2018-09-05 13:37:45 -07:00
Brian Cain
c3c65a3793
Fixup docs and website wording for command
2018-09-05 13:26:22 -07:00
Brian Cain
b1a0fa628f
Add subcommand docstring to powershell
2018-09-05 12:56:17 -07:00
Brian Cain
d6e43d3197
Include winrm locales
2018-09-05 11:00:45 -07:00
Sebastian Reuße
3efdc8960c
vagrant init: Support VAGRANT_DEFAULT_TEMPLATE
2018-09-04 10:48:16 +02:00
Brian Cain
f51176a101
Merge pull request #10140 from berney/fix-ansible-perm-issue
...
Fix ansible_local provisioner permission bug
2018-08-31 11:02:47 -07:00
Brian Cain
11c619bff6
Merge pull request #10092 from jmaness/patch-1
...
[#10098 ] Filter out empty strings and loopback interfaces when constructing the list of network interfaces
2018-08-31 10:03:49 -07:00
Chris Roberts
c4084a6387
Extract smblist information based on position
...
Since we are no longer extracting information based on key value due
to localization issues, use start and end locations to extract data.
This prevents errors when extra information is included like Scope.
2018-08-30 10:58:56 -07:00
Chris Roberts
d48b95ffaf
Check :verify_host_key value for :never or if falsey
2018-08-24 14:11:30 -07:00
Berne Campbell
b036032cb0
fix typo
2018-08-23 13:07:56 +10:00
Berne Campbell
0d23724a1f
Fix ansible provisioner permission bug
2018-08-22 20:32:40 +10:00
Brian Cain
b1357a2f60
Merge pull request #10123 from briancain/add-force-flag-reload
...
Add `--force` flag to reload command
2018-08-17 15:18:36 -07:00
Brian Cain
c2cff0dc07
Merge pull request #10100 from briancain/DOCKER-TOOLBOX
...
Convert windows paths for volume mounts on docker driver
2018-08-17 15:08:59 -07:00
Brian Cain
e5364e7798
Only write box metadata if guest has box object
...
Prior to this commit, providers like docker would fail to be brought up
because they do not store box objects like virtualbox or vmware
provider guests. This commit fixes that by making sure the box object
exists before writing the metadata file to disk.
2018-08-17 09:58:24 -07:00
Brian Cain
c65a0a9054
( #9677 ) Add `--force` flag to reload command
...
This commit introduces the `--force` flag to the reload command. This
change means that if the flag is included, the halt step of the reload
will forcefully shutdown the virtual machine rather than a graceful
halt.
2018-08-16 13:57:13 -07:00
Brian Cain
5d2d784ae7
( #9085 ) - Add test for converting windows paths
...
This commit adds a test for checking that a windows path for mounting a
volume in a container is properly converted into something that's
usable.
2018-08-08 10:30:04 -07:00
Chris Roberts
2c4c14c57c
Merge pull request #10084 from chrisroberts/f-host-nfs-sudo
...
Fix sudo usage in exports write within linux host cap
2018-08-08 08:28:49 -07:00
Chris Roberts
8ec7963968
Merge pull request #10083 from chrisroberts/f-box-ver-up
...
Store box metadata of active guest
2018-08-08 08:25:47 -07:00
Brian Cain
9ec2eae5c9
Merge pull request #9976 from Biteable/fix-cmd-command
...
Allow shared folders to be mounted after installing MSYS2
2018-08-07 13:13:05 -07:00
Jeremy Maness
a73fb9c139
- Filter out empty strings when constructing the list of network interfaces
...
- Sort interfaces properly whose name does not contain a numeric suffix (e.g. lo)
- Filter out loopback interfaces
2018-08-04 21:16:51 -04:00
Chris Roberts
ceb7a0b5ac
When doing box lookup, use explicit provider, machine provider, then default
2018-08-02 16:41:28 -07:00
Chris Roberts
00b783a6a5
Lookup latest available installed box if required on update
...
When performing a box update and the box version has been updated
to be different than the installed version, perform a lookup for
the latest available installed box to allow the update command to
continue successfully
2018-08-02 16:12:10 -07:00
Chris Roberts
051c7a7823
Fix sudo usage in exports write within linux host cap
...
Only move new exports file to destination without sudo when the
file has write access and the directory has write access. Always
use sudo when changing file ownership.
2018-08-02 15:13:27 -07:00
Chris Roberts
6c1a9dc58e
Store box metadata of active guest
...
When a guest is created, the box metadata information is stored in the
machine data directory. This allows modifications to happen to the
Vagrantfile definition of the box in use (box name change, box version
change, etc) while still allowing the Machine instance of an active
guest successfully load the box currently backing it.
2018-08-02 11:01:36 -07:00
Brian Cain
b3da2bd21f
( #9614 ) Add back check for Solaris derived guests
...
This commit adds back the `uname` test 93c571adbf
removed to catch any solaris 11 derived guests like openindiana
2018-08-01 14:25:04 -07:00
Chris Roberts
de284a9056
Merge pull request #10079 from chrisroberts/f-win-virt-ext
...
Enable ExposeVirtualizationExtensions only when available
2018-07-31 13:54:55 -07:00
Chris Roberts
09c8e2800c
Merge pull request #10077 from chrisroberts/e-ipv6-link-local
...
Skip link-local addresses when fixing IPv6 route
2018-07-31 13:52:50 -07:00
Chris Roberts
e3e68c9b51
Merge pull request #10076 from chrisroberts/e-winrm-warn
...
Add warning when vagrant-winrm is found
2018-07-31 13:51:23 -07:00
Chris Roberts
fa9bda9554
Merge pull request #10066 from chrisroberts/e-net-ssh-update
...
Update net-ssh constraint
2018-07-31 13:48:49 -07:00
Chris Roberts
9c149ba8b1
Only enable ExposeVirtualizationExtensions if available within Hyper-V version
2018-07-31 13:33:41 -07:00
Cédric Félizard
f53238d253
Skip link-local addresses when fixing IPv6 route
...
This occurs with a Linux host when a link-local address is configured
for vboxnet0 (which is the default for VirtualBox 5.2.6).
`connect': Invalid argument - connect(2) for "fe80::ffff:ffff:ffff:ffff" port 80 (Errno::EINVAL)
2018-07-30 15:00:35 -07:00
Chris Roberts
dcfb84893d
Only reset the _init on testing cleanup
2018-07-30 14:44:36 -07:00
Chris Roberts
cd7215ab13
Add warning when vagrant-winrm is found
2018-07-30 13:27:20 -07:00
Chris Roberts
57e0bb5105
Update net-ssh constraint
...
Also includes mapping of verify_host_key value to new values
introduced in 5.0.0
2018-07-27 16:30:06 -07:00
Matthew Olenik
428eb3ed93
Support Docker volume consistency for synced folders
...
Adds the `docker_consistency` option, which sets the Docker volume
consistency level. This can be used to greatly improved synced folder
performance, especially on macOS.
See for details: moby/moby#31047
2018-07-27 15:16:39 -07:00
Brian Cain
72f3a7be14
Ensure the SecureRandom library is loaded
2018-07-27 13:44:24 -07:00
Chris Roberts
8ff29d5c05
Merge pull request #10043 from chrisroberts/f-smb-localization
...
Remove localization dependency from SMB list generation
2018-07-27 10:27:54 -07:00
Chris Roberts
584b288b8f
Merge pull request #9935 from whitel/fix-for-#9878
...
Fixes the change in packaging for nfs in f28 (#9878 )
2018-07-27 10:22:42 -07:00
Chris Roberts
a993cbce4e
Merge pull request #10037 from chrisroberts/e-vagrant-plugins-local
...
Define project specific plugins
2018-07-27 09:57:41 -07:00
Chris Roberts
4d4e707b73
Merge pull request #9889 from treytabner/debian-systemd-networkd
...
Increase priority and support multiple networks for Debian with systemd-networkd
2018-07-19 14:13:46 -07:00
Chris Roberts
2096bce36f
Remove localization dependency from SMB list generation
2018-07-19 13:40:54 -07:00
Chris Roberts
27a441f0bd
Merge pull request #10001 from chrisroberts/e-wsl-valid-sync
...
Disable synced folders on non-DrvFs
2018-07-18 16:41:16 -07:00
Chris Roberts
110600970a
Merge pull request #10000 from chrisroberts/f-hyperv-access-localized
...
Fix Hyper-V access check
2018-07-18 16:39:54 -07:00
Chris Roberts
10faa599e7
Merge pull request #9999 from chrisroberts/f-hyper-v-snaps
...
Enable checkpoints for snapshots if disabled
2018-07-18 16:38:32 -07:00
Chris Roberts
7c9fb9a5d7
Use availablity of local plugins file instead of option
2018-07-18 15:49:30 -07:00
Chris Roberts
8e0e2fc53a
Add output for local repair
2018-07-18 15:49:30 -07:00
Chris Roberts
8445b496d8
Use consistent terms for describing local flag
2018-07-18 14:19:29 -07:00
Chris Roberts
7a623d2826
Include local flag for plugin update command
2018-07-18 14:02:17 -07:00
Chris Roberts
3fd55dac23
Add local plugin repair support. Update global repair implementation.
2018-07-18 13:46:17 -07:00
Chris Roberts
ef0269c538
Add action method for local plugin repair
2018-07-18 13:45:15 -07:00
Chris Roberts
14edb8f423
Add local only and global only flags to plugin expunge command
2018-07-18 13:43:52 -07:00
Chris Roberts
9d191a2419
Add local option stub to allow Vagrantfile loading
2018-07-17 15:35:25 -07:00
Chris Roberts
8baf7ced38
Use path of state file, not state file itself
2018-07-17 15:35:25 -07:00
Chris Roberts
3223737734
Use env_local consistently internally
2018-07-17 14:49:41 -07:00
Chris Roberts
b71054502e
Update local usage to env_local for clarity
2018-07-17 14:49:41 -07:00
Chris Roberts
84c0aafe71
Support non-interactive local plugin install
2018-07-17 14:49:41 -07:00
Chris Roberts
40f4e6f67e
Vagrant Environment isolated plugins
...
Adds support for plugins isolated to a specific `Vagrant::Environment`
which can be managed by the vagrant plugin command using the the
--local flag.
2018-07-17 14:49:41 -07:00
Aloz1
b9b9eeac85
Void requires root access to check service status
...
Service status check was failing because it was not being run as root. This resulted in vagrant thinking the service was not running, hence it would always try to start nfs rather than updating exports.
2018-07-14 15:53:13 +10:00
Chris Roberts
8aa74a03a0
Differentiate checkpoints and automatic checkpoints
...
Provide separate configuration settings for enabling/disabling
checkpoints and automatic checkpoints with Hyper-V provider.
2018-07-13 15:23:09 -07:00
Aloz1
5e258cbc7c
Fixed nfs_start_command. NFS now starts.
2018-07-13 08:08:05 +10:00
Aloz1
98f70d4d7a
Add void linux host support
2018-07-12 08:40:33 +10:00
Brian Cain
52c3dcc70e
( #9997 ) Catch and allow for non-standard exit codes
...
Prior to this commit, the run trigger option wouldn't catch for failures
outside of the #Subprocess.execute raising exceptions. This commit fixes
that by inspecting the exit code result of the subprocess and using the
new `exit_codes` option to determine how to move forward with the
trigger.
2018-07-09 15:56:26 -07:00
Chris Roberts
2667de163b
Enable rsync synced folders for non-DrvFs file systems within WSL
2018-07-06 16:58:12 -07:00
Chris Roberts
859d48d5f5
Restrict synced folder access to DrvFs file systems only within WSL
2018-07-06 16:58:12 -07:00
Chris Roberts
cf29085d33
Fix root directory generation on failed access
2018-07-06 16:27:52 -07:00
Chris Roberts
15dacc80c0
Update ACL check to use identifier to prevent localization errors
2018-07-06 16:25:05 -07:00
Chris Roberts
a9bc0bb800
Do not provision and configure when state is saved
2018-07-06 15:49:36 -07:00
Chris Roberts
630bc6540d
Enable standard checkpoint on VM for snapshot if disabled
2018-07-06 15:29:07 -07:00
William Bowling
4ec865b69d
Make sure that the correct cmd is run
...
After installing msys2, there is another `cmd` on the path which prevents shared folders from being mounted. Explicitly calling `cmd.exe` fixes the issue
2018-07-02 13:15:10 +10:00
Chris Roberts
ac8ad59823
Provide custom error when attempting to push too many files with FTP
...
When the configured directory for FTP push has too many files, it will
generate an exception and fail due to a stack overflow. When this happens
just rescue out the exception and re-raise a custom error to provide
some context to the user on the actual problem.
2018-06-26 08:28:01 -07:00
Chris Roberts
101fc447ec
Add Hyper-V access check on data directory
2018-06-18 15:36:45 -07:00
Chris Roberts
941dd77a90
Force string conversion on paths
2018-06-18 09:53:06 -07:00
langdon
f0b9d025e4
Fixes the change in packaging for nfs in f28 ( #9878 ). However, removed part of the unit test which will be very difficult to fix (I expect). The unit test is still doing a good test that nfs and rpcbind work though. If you go far enough back, you need to bury the error out too.
2018-06-18 12:16:23 -04:00
Chris Roberts
fe8fe55d1f
Delete and re-create data directory when destroying guest
2018-06-18 09:09:27 -07:00
Chris Roberts
a8abb6898c
Fix PowerShell cmdlet name for clones
2018-06-18 09:09:01 -07:00
Chris Roberts
1e5c8bf275
Add check for WSL when determining if Hyper-V is usable
2018-06-18 09:08:35 -07:00
Chris Roberts
d84f29f12c
Just provide module path as conversion is done earlier
2018-06-18 09:08:05 -07:00
Chris Roberts
55aaa1d258
Update path usages to support Hyper-V provider access from WSL
2018-06-15 09:03:18 -07:00
Chris Roberts
8fbf27772a
Always ensure full path to configuration file on import
2018-06-15 07:48:14 -07:00
Chris Roberts
694104b005
Attempt to provide helper error message on failed VM import
...
When importing a Hyper-V VM fails, attempt to manually build
a system definition and inspect the result to determine cause
of the failure.
2018-06-14 16:40:37 -07:00
Chris Roberts
3919455f08
Merge pull request #9932 from chrisroberts/e-hyperv-maxmem-chk
...
Validate maxmemory setting within Hyper-V provider
2018-06-13 14:52:09 -07:00
Chris Roberts
4d3f5d33c6
Merge pull request #9925 from chrisroberts/u-powershelling
...
Misc. PowerShell cleanup
2018-06-13 14:51:43 -07:00
Chris Roberts
9482f351fc
Validate maxmemory setting within Hyper-V provider
...
Forces an error if maxmemory value is less than the configured
minimum or startup memory.
Fixes #9477
2018-06-13 13:27:11 -07:00
Trey Tabner
c218267436
Merge branch 'master' into debian-systemd-networkd
2018-06-13 12:49:50 -05:00
Chris Roberts
1554f447f2
Disconnect all configured network adapters
...
When importing a Hyper-V VM ensure all adapters are disconnected from
switches that were used when the box was built.
2018-06-13 07:59:56 -07:00
Chris Roberts
10ac204c29
Prevent SMB output from being wrapped
2018-06-12 16:47:47 -07:00
Chris Roberts
57842d7269
Update powershell messaging functions to not include second `-` character.
2018-06-12 16:47:47 -07:00
Chris Roberts
ee5656da37
Merge pull request #9923 from chrisroberts/f-win-perms
...
Update SSH key file permissions handling
2018-06-12 16:45:39 -07:00
Chris Roberts
4bf8fe1463
Merge pull request #9917 from chrisroberts/f-smb-garbage
...
Fix SMB information generation when using net share
2018-06-12 16:24:54 -07:00
Chris Roberts
e39b3555e6
Disable inherit on key file for parent ACL rules
2018-06-12 16:21:13 -07:00
Chris Roberts
ae8e25aabc
Include key path flag when calling script
2018-06-12 16:20:49 -07:00
Chris Roberts
16bcc1d874
Include scripts directory when building pathname
2018-06-12 16:20:30 -07:00
Chris Roberts
2628d93370
Rename method name when checking capability
2018-06-12 14:13:10 -07:00
Chris Roberts
98c6903e9c
Fix path variable name. Return process result.
2018-06-12 11:56:37 -07:00
Chris Roberts
a5582eb1c8
Add ssh key permissions set caps to hosts
2018-06-12 10:49:10 -07:00
Chris Roberts
5ba91de4d8
Use host capability to update key file permissions if available
2018-06-12 10:46:53 -07:00
Chris Roberts
ef5eca16d2
Fix SMB information generation when using net share
...
Adds the final line of output to tests and properly simulates
failure. Fix with type casting to prevent calling methods on
nil and drop the final entry as it's not valid.
Fixes #9806
2018-06-11 12:58:35 -07:00
Chris Roberts
7df6ea5a30
Fix Chef apply provisioner to not set node_name
...
The base chef provisioner class will set the node name automatically
if not provided in the configuration. Since the chef apply provisioner
does not provide a node_name option, setting it will invalidate the
configuration. This checks for the node name before attempting to
use it.
Fixes #9901
2018-06-11 10:35:52 -07:00
Chris Roberts
52c174da75
Merge pull request #9833 from afischer-opentext-com/9174
...
#9174 Remove masterless? config attribute
2018-06-08 16:18:06 -07:00
Chris Roberts
6f76275f9e
Merge pull request #9867 from jnahorny/fix-9592-systemd-networkd
...
Fix issue 9592 when systemd-networkd is used by Debian guest
2018-06-08 16:08:27 -07:00
Chris Roberts
9001dc6b9b
Merge pull request #9855 from WIgor/master
...
Fix for ubuntu 17.10+ netplan
2018-06-08 16:03:07 -07:00
Tony Apuzzo
5ac8bb8620
Correct typo, $Enable instead of $enabled.
2018-06-07 15:00:09 -06:00
Chris Roberts
120fa07a8d
Merge pull request #9872 from chrisroberts/e-hyperv-2
...
Hyper-V provider overhaul
2018-06-04 16:51:12 -07:00
Gilles Cornu
d5b5e9ea8c
ansible_local: Improve installation from PPA
...
- Fix #9796 : Failing installation on bionic (18.04 LTS)
- Remove support for precise (12.04 LTS), which is out of public support
(On this version, the package python-software-properties contained
the add-apt-repository tool)
- Reduce the number of SSH calls, and avoid unnecessary apt-get calls.
2018-05-31 05:47:50 +02:00
Trey Tabner
59474f80fd
Increase priority and support multiple networks
2018-05-30 10:10:36 -05:00
Chris Roberts
73c09de1a9
Add deprecation warning when `differencing_disk` option is used
2018-05-29 10:21:06 -07:00
Chris Roberts
c238dc0a35
Include machine name when raising invalid box errors
2018-05-25 16:43:17 -07:00
Chris Roberts
35d8920325
Case insensitive switch check and only write sentinel file if not found
2018-05-25 15:11:58 -07:00
Chris Roberts
2bd6f537ef
Clean up syntax and force string type when setting integration option
2018-05-25 10:11:05 -07:00
Chris Roberts
d2bc634623
Add vm_integration_services validation
2018-05-24 16:55:35 -07:00
Chris Roberts
52bae21933
Remove unused PowerShell scripts
2018-05-24 15:33:36 -07:00
Jaroslaw Gorny
995c43dd0c
Fix issue 9592 when systemd-networkd is used by Debian guest
2018-05-25 00:06:20 +02:00
Chris Roberts
e6457d5061
Overhaul the Hyper-V provider
2018-05-24 14:43:44 -07:00
Igor Mazur
66b2866373
Shorten if
2018-05-23 11:17:40 +03:00
Igor Mazur
07bbaf9ac5
Fix fo tests (symbol and string dhcp)
2018-05-22 23:29:53 +03:00
Igor Mazur
be096c3ef4
Fix for ubuntu 17.10+ netplan
...
https://github.com/hashicorp/vagrant/issues/9570
2018-05-21 23:48:40 +03:00
Brian Cain
c6cd8f1e9a
Merge pull request #9829 from briancain/add-suspend-global
...
Introduce flag for suspending all machines
2018-05-11 16:41:24 -07:00
Brian Cain
5ca382727d
Raise error if argument is provided with `--all-global` flag
...
This commit raises an error if additional arguments are provided to the
suspend command when the `--all-global` flag is used.
2018-05-11 15:43:14 -07:00
Brian Cain
aa5687cd14
( #7221 ) Introduce flag for suspending all machines
...
This commit introduces a new flag to the suspend command,
`--all-global`, which will suepend all vms both locally and globally.
2018-05-11 10:15:48 -07:00
Alexander Fischer
0b87184ad4
#9174 Remove masterless? config attribute
...
Remove the @config.masterless? attribute as there is no benefit from it
2018-05-11 08:49:57 +02:00
Brian Cain
728a9135c8
( #9726 ) Update netplan config generation to detect NetworkManager
...
Prior to this commit, when setting up private networks on Ubuntu using
netplan, it assumed that the guest was using systemd, the suggested
default tool to manage networking, and did not take into account devices
that could be managed with NetworkManager. This commit fixes that by
looking at the devices managed on the guest to see if its managed by
NetworkManager, and if so, use that renderer for netplan instead of
networkd.
2018-05-10 13:02:05 -07:00
Chris Yungmann
7fb9d3eb4f
propagate unset guestpath
2018-05-08 22:51:30 -05:00
Chris Roberts
3bcdd2901b
Merge pull request #9800 from chrisroberts/e-vbox-builtin
...
Support VirtualBox shared folders using builtin kernel module
2018-05-07 13:24:50 -07:00
Chris Roberts
0a523bc12b
Merge pull request #9785 from chrisroberts/f-smb-list
...
Use net.exe to fetch SMB shares when Get-SmbShare is not available
2018-05-07 13:07:47 -07:00
Chris Roberts
c571249000
Support VirtualBox shared folders using builtin kernel module
...
Check error output if initial mount command fails to determine if
the builtin module should be used for mounting instead.
2018-05-07 13:02:19 -07:00
Chris Roberts
7a4150dc3f
Use net.exe to fetch SMB shares when Get-SmbShare is not available
...
Fixes #9547
2018-05-04 14:07:33 -07:00
Chris Roberts
2730fe7ec9
Update script parameter name in option to switchid
...
Fixes #9774
2018-05-04 08:55:18 -07:00
Chris Roberts
02b9d625d3
Merge pull request #9759 from StefanScherer/wsl-remove-raise-vboxmanage-missing
...
Allow other providers in WSL
2018-05-03 12:42:16 -07:00
Chris Roberts
89d00f4204
Merge pull request #9758 from StefanScherer/wsl-rdp
...
Call mstsc.exe Windows RDP client in WSL
2018-05-03 12:40:37 -07:00
Chris Roberts
40ae8aa38d
Merge pull request #9769 from chrisroberts/e-key-perms
...
Log error and proceed when private key permissions fail
2018-05-03 12:34:50 -07:00
Chris Roberts
f0e232d739
Log error and proceed when private key permissions fail
...
Fixes #9765
2018-05-03 11:48:57 -07:00
Chris Roberts
8b398b66a3
Trim drive letter prefix from path
...
Fixes #9764
2018-05-03 09:28:19 -07:00
Brian Cain
e1129d27f9
Merge pull request #9761 from briancain/FIX-DOCKER-EXEC
...
Use Util::SafeExec if docker-exec is run with `-t` option
2018-05-02 15:47:46 -07:00
Brian Cain
79e535a7ee
( #9622 ) Use SafeExec for docker-exec
...
This commit uses the internal helper SafeExec rather than using the
Kernel class directly. It also adds a test to ensure that if the `-t`
option is used, it will call SafeExec.
2018-05-02 14:23:50 -07:00
Stefan Scherer
f14e8bcbf2
Allow other providers in WSL
2018-05-02 22:36:17 +02:00
Chris Roberts
fbcd86993b
Merge pull request #9737 from chrisroberts/e-hyper-v-addr
...
Check neighbors for valid guest address when default lookup fails
2018-05-02 08:54:57 -07:00
Chris Roberts
bf281a912c
Merge pull request #9747 from chrisroberts/e-hyper-v-checkpoints
...
Reference Hyper-V switch by ID instead of name
2018-05-02 07:47:31 -07:00
Stefan Scherer
a01d68b2e0
Call mstsc in WSL
2018-05-02 15:21:47 +02:00
Brian Cain
6fc2d9d82d
Merge pull request #9754 from briancain/DOCKER-PROV-WINDOWS
...
Update docker provisioner for windows, fix command filter behavior for `rm`
2018-05-01 13:46:33 -07:00
Brian Cain
93356d4635
Update rm filters to test for path
...
This commit updates the rm filter for winrm to operate like how rm works
in bash. If a folder doesn't exist, the command returns 0 rather than 1.
2018-05-01 13:35:45 -07:00
Chris Roberts
9f08337ce1
Ignore errors on neighbor lookup and validate result
2018-04-30 17:39:27 -07:00
Chris Roberts
39bb589f7d
Merge pull request #9739 from chrisroberts/f-midware-invalid-uri
...
Ignore URLs which cannot be parsed in the authentication middleware
2018-04-27 17:03:02 -07:00
Chris Roberts
e47e1df228
Reference Hyper-V switch by ID instead of name
...
Keep track of selected Hyper-V switch using the ID instead of name
to prevent any encoding issues that may occur switching between
PowerShell and Ruby. With the IDs staying consistent, the switch
name can be fetched from the provided ID.
Fixes #9679 #8794 #9451
2018-04-27 16:52:16 -07:00
Joe Pleso
c882d888a7
Add docker cap to windows to detect daemon and fix whitespace
2018-04-27 09:45:24 -07:00
Brian Cain
1f25b2cc22
Merge pull request #9736 from briancain/disable-loading-triggers-if-plugin-exists
...
Add warning if vagrant-triggers plugin is installed
2018-04-26 16:11:31 -07:00
Chris Roberts
97f5822dee
Ignore URLs which cannot be parsed in the authentication middleware
...
Fixes #9725
2018-04-26 15:08:06 -07:00
Brian Cain
1ef45d8073
Add warning if vagrant-triggers plugin is installed
...
To allow users to continue to use the community plugin, this commit adds
a switch that will not load the core trigger feature if it detects the
community plugin is installed. It also allows the user to disable the
warning so they can continue to use the plugin without extra output.
2018-04-26 14:59:09 -07:00
Chris Roberts
d2ec4d9312
Merge pull request #9734 from chrisroberts/f-win-smb-mount
...
Default SMB version to 2.0 for linux guest mounts on Windows hosts
2018-04-26 14:48:01 -07:00
Chris Roberts
d15ff38d5c
Check neighbors for valid guest address when default lookup fails
...
If the guest address is unavailable via Hyper-V inspection, extract
MAC address of network adapters and check neighbor information for
any currently matching known address.
2018-04-26 12:53:52 -07:00
Chris Roberts
40a1d2faf3
Default SMB version to 2.0 for linux guest mounts
...
Fixes #8959
2018-04-26 08:45:05 -07:00
Chris Roberts
5feb234665
Return original URL value when unmodified
...
Due to the behavior of URI.parse on Ruby < 2.5 returning the string
value of the parsed URI object may modify the original URL. Specifically
it will remove the `//` prefix characters from SMB paths. When no
host modifications are being made, always return the original value.
Fixes #9636
2018-04-25 16:21:21 -07:00
Brian Cain
b409f0e203
Merge pull request #9669 from dduponchel/data_bags_path
...
Support arrays for data_bags_path in chef-zero
2018-04-24 15:45:36 -07:00
Brian Cain
5643ba0c7d
Merge pull request #9713 from briancain/vagrant-triggers-config
...
Integrate vagrant-triggers plugin functionality into core Vagrant
2018-04-24 11:35:04 -07:00
Brian Cain
a9be56b356
Code updates based on PR feedback
2018-04-24 10:04:40 -07:00
Brian Cain
7f004656db
( #9718 ) Properly finalize structured_facts config option
...
This commit sets the structured_facts option to nil if its still
UNSET_VALUE at the finalize step. This was causing a bug when the facter
config was set but was not using structured facts.
2018-04-23 14:23:59 -07:00
Brian Cain
e25cb51f15
Properly print warnings on config settings that aren't supported
2018-04-20 10:51:38 -07:00
Brian Cain
12b1a3dfe4
Update triggers based on code review
2018-04-20 10:51:38 -07:00
Brian Cain
e0806f623c
Remove TODO
2018-04-20 10:51:38 -07:00
Brian Cain
0054c5aae6
Raise error if incomplete trigger block is defined
2018-04-20 10:51:38 -07:00
Brian Cain
767a315393
Trigger cleanup
2018-04-20 10:51:38 -07:00
Brian Cain
693eb2fbbb
Add machine level warning when privileged option is set for run
2018-04-20 10:51:38 -07:00
Brian Cain
3ad4f576c0
Add only_on validation for config
2018-04-20 10:51:38 -07:00
Brian Cain
ca672eb8e6
Trigger plugin cleanup
2018-04-20 10:51:38 -07:00
Brian Cain
85dedf25d9
Ensure that :all triggers don't get filtered out
2018-04-20 10:51:38 -07:00
Brian Cain
2c30eab723
Don't run local commands as sudo by default
2018-04-20 10:51:38 -07:00
Brian Cain
eac2fcf71e
Filter triggers based on only_on restraint
2018-04-20 10:51:38 -07:00
Brian Cain
372a6a7911
Initial trigger plugin scaffolding
2018-04-20 10:51:38 -07:00
Brian Cain
a5d8cc1caa
Update trigger classes with comments
2018-04-20 10:51:38 -07:00
Brian Cain
956ed004bb
Update trigger config merge function
2018-04-20 10:51:38 -07:00
Brian Cain
abb6d77442
Move location of command validator
2018-04-20 10:51:38 -07:00
Brian Cain
6cbb5d8e5d
Add unit tests for config, fix type change bug with map!
2018-04-20 10:51:38 -07:00
Brian Cain
42419bbd49
Fix rspec tests
2018-04-20 10:51:38 -07:00
Brian Cain
d0d69e59c9
Update return doc string on validate
2018-04-20 10:51:38 -07:00
Brian Cain
60c4ffa8a6
Ensure run & run_remote are Hashes before updating to shell config
2018-04-20 10:51:38 -07:00
Brian Cain
e752878de9
Update finalize method for run and run_remote objects
2018-04-20 10:51:38 -07:00
Brian Cain
d3dde739fe
Update trigger code docs
2018-04-20 10:51:38 -07:00
Brian Cain
1591ae9916
Make run and run_remote settings shell provisioner configs
2018-04-20 10:51:38 -07:00