According to the docs, for volumes and backingStores: "The mode defaults to
0600 when not provided. https://libvirt.org/formatstorage.html
Removing this setting here allows the pool configuration to set the default
mode.
- Explicitly disable any SSH multiplexing here so PID tracking of
tunnels works correctly.
- Using `exec ssh` in the spawn forces Ruby to use a subshell (as exec
is a shell builtin) instead of spawning the ssh process directly, which
results in getting the wrong (and dead, as the exec replaces the
subshell) PID to track and clean up later.
- Run the ssh tunnel command on its own process group, essentially
daemonizing it and keeping its PID intact even when `vagrant up` command
is run on shell/consoles without an explicit TTY, such as Emacs Eshell.
Make it easier to tweak some qemu options by allowing passthru of
command line environment variables.
- Also cleans up weird variable indirection used for qemu commandline args
variable through `qargs` in various constructors.
- Addresses some functionality discussed in #776.
Bring the TOC in line with recent additions and enable the ability to
use a vim plugin to quickly regenerate in lieu of a better alternative.
Using https://github.com/mzlogin/vim-markdown-toc
Clean up any trailing whitespace so that subsequent file updates
by other PRs will be able to simply regen using appropriate tooling
without pulling in additional changes unrelated.
Packaging an existing vagrant environment relied on copying the backing
image. Users may not have permission to read this file despite being
able to interact with it through libvirt.
Use ruby-libvirt to download the image instead so any user with libvirt
access can run the package command.
Uncomment NFS prune action
If the user has not configured NFS for any of the synced folders, then
it is likely they are not expecting to be asked for a sudo password on
destroy. Move the test for using NFS to a common module and include in
both the preparing and pruning actions.
Co-authored-by: Darragh Bailey <daragh.bailey@gmail.com>
The fog-libvirt volumes filter behaves differently than the others in
that it returns an empty volume object if nothing is found. This has the
potential to change in the future so guard against an empty result as
well by checking if the assigned first element is nil.
This commit replaces the pattern where the metadata for all volumes,
servers, or pools was downloaded and then searched. Instead a filter
argument is passed to the connection and only the metadata for the named
resource is returned, if it exists. This results in significant speed
increases for libvirt hosts that are offsite or have many volumes.
Latest vagrant depends on a vagrant-spec release containing a more
recent dependency on childprocess than is supported for earlier releases
of vagrant.
Adjust dependencies to pin to the specific release of vagrant-spec if
the request version of vagrant is 2.2.7 or older.
Does not attempt to handle the situation where a version is specified
that cannot be parsed.
While it would be useful to test against newer versions of 2.2.x, it
appears this encounters a bug in upstream vagrant when installing in
dev mode see https://github.com/hashicorp/vagrant#11293
Therefore limit latest 2.2.x released version tested against to 2.2.4.
Warden will call the recover method when env[:interrupted] is set, so
just return instead and let it walk the stack to perform cleanup. This
ensures that during the WaitTillUp action that the user setting to
disable destroy_on_error is respected should the exception occur during
looking for the IP address or SSH connection.