Commit Graph

2990 Commits

Author SHA1 Message Date
Brian Cain 00e0dc9279
Merge pull request #11076 from dcermak/suse_nfs_support
Update nfs & service daemon names for suse based hosts
2019-10-08 13:41:22 -07:00
Chris Roberts 04a1bb58f3 Add coverage on new behavior of FileChecksum 2019-10-08 11:23:48 -07:00
Chris Roberts 0bce1e6307 Update tests for checksum and filechecksum 2019-10-08 11:23:48 -07:00
Chris Roberts 7fb81bcea1 Add support for other checksum types 2019-10-08 11:23:48 -07:00
Brian Cain ea550289a9
Merge pull request #11100 from chkpnt/suse-hostname
Use hostnamectl instead of hostname to set the hostname under SUSE
2019-10-08 09:26:46 -07:00
Brian Cain 7616c99c79
Merge pull request #11106 from briancain/bug/docker_compose_build_args
Ensure build_args are passed into docker compose config file
2019-10-07 14:30:30 -07:00
Brian Cain d6f556c83d
Merge pull request #11099 from briancain/file-provisioner-source-path
Ensure relative path for file provisioner is relative to machines cwd
2019-10-07 14:28:13 -07:00
Brian Cain f1ea4eaac0
Ensure build_args are passed into docker compose config file
Prior to this commit, the docker compose build method would not properly
set build_args if given in a Vagrantfile. This commit fixes that by
using the passed in key `extra_args` from the docker build action.
2019-10-07 12:48:59 -07:00
Brian Cain 96e275451c
Merge pull request #10938 from andersk/virtualbox-usable
virtualbox: Fix usability test to reject bad installs without crashing
2019-10-07 09:04:24 -07:00
Anders Kaseorg 4afd370d6a virtualbox: Fix usability test to reject bad installs without crashing
If VirtualBox is installed but the kernel module is missing or the
service is stopped, the usability test should fail without crashing so
we can fall back to other providers.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-10-04 15:56:10 -07:00
Gregor Dschung 8442b6b59f Use hostnamectl instead of hostname to set the hostname under SUSE 2019-10-03 14:46:14 +02:00
Brian Cain 0a6c4e2d0f
Ensure relative path for file provisioner is relative to machines cwd
Prior to this commit, if you ran Vagrant in a different current working
directory other than where a current guest machines location is, the
file provisioner would not take into account the machines local dir, and
would instead use the path where Vagrant was invoked to expand the
`source` path option for a file provisioner. This commit fixes that by
passing the root path `machine.env.cwd` when expanding the source dir.
2019-10-02 15:33:23 -07:00
Brian Cain 968a126405
Merge pull request #11098 from briancain/finalize-ansible-config-values
Fixes #10950: Ensure pip_install_cmd is finalized
2019-10-02 12:51:33 -07:00
Brian Cain 23352d406c
Merge pull request #11097 from briancain/hyperv-command-snapshot-save-fix
Fixes #11027: Ensure VM id is passed to list snapshots
2019-10-02 12:49:38 -07:00
Brian Cain 96c20ad3cc
Fixes #10950: Ensure pip_install_cmd is finalized
Prior to this commit, the `pip_install_cmd` option for ansible guest
config was not properly finalized. This commit ensures that if that
value is still UNSET_VALUE, it gets set to empty string in the finalize!
method.
2019-10-02 10:33:31 -07:00
Brian Cain 66ec57a637
Fixes #11027: Ensure VM id is passed to list snapshots
Prior to this commit, if you tried to save a snapshot without giving it
a name, the hyper-v driver would not properly obtain a vm id to save a
snapshot on, resulting in an error. This commit updates the command
snapshot save to hold onto the machines ID in argv rather than `pop` it
off, so that the hyperv driver can obtain the guests id when saving a
snapshot.
2019-10-01 13:33:39 -07:00
Brian Cain 1c620852b6
Fixes #10966: Ensure all subdirectory files are watched
Prior to this commit, due to a fix that ignored `.vagrant` with rsync
helper, it broke the ability to watch for changes in subdirectories when
running the rsync-auto command. This commit puts back some of the helper
methods that were there previously for a given watcher path to ensure
that all files and subdirectories are properly watched and synced.
2019-09-26 08:29:37 -07:00
Dan Čermák a3588c28a8
Update nfs & service daemon names for suse based hosts
- nfs.service got recently removed in openSUSE Tumbleweed and calling service
  restart nfs errors out on Tumbleweed. nfs.service has been an alias to
  nfs-client.target for a very long time and can thus be safely substituted.
- all actively supported versions of openSUSE & SLE are using systemd now
  => no reason not to use systemctl
2019-09-18 23:28:18 +02:00
Brian Cain c7b1f8821d
Try to mock up docker version subprocess result in test 2019-09-11 09:36:11 -07:00
Brian Cain d4002aa74d
Add vagrantfile mock to iso_env machine 2019-09-11 09:17:14 -07:00
Brian Cain e820b5df8e
Add vagrantfile double for environment class 2019-09-11 09:01:35 -07:00
Brian Cain f14cf09af6
Add allow for docker driver execute method 2019-09-11 08:37:07 -07:00
Brian Cain 21db2db9ac
Add machine config to machine double for rspec tests
This commit mocks up the docker machines test config so that it doesn't
actually invoke the docker driver in circle-ci
2019-09-11 08:09:26 -07:00
Brian Cain ebe1f3f1c9
Remove virtualbox context from docker tests 2019-09-11 07:46:40 -07:00
Anders Kaseorg 5b4dcf9443
providers/docker: Fix usability check
In commit 7980178d19 (#10879) I added a
`usable?` class method to `VagrantPlugins::DockerProvider::Provider`.
However, commit 34e53a5a4b (#10890)
incorrectly changed it to an instance method.  This rendered it
ineffective because it’s called on the class, not an instance.  Change
it back to a class method.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-09-10 15:10:43 -07:00
Brian Cain 8abc0cc90c
Merge pull request #11013 from dcermak/suse_ipv6_support
Add ipv6 network config templates for SUSE based distributions
2019-09-06 11:08:37 -07:00
Brian Cain f74239bed9
Merge pull request #11043 from briancain/provisioner-enhancements
Introduce new Provisioner options: before and after
2019-09-06 08:52:40 -07:00
Brian Cain f9b60ba603
Merge pull request #11052 from briancain/add-skip-used-boxes-with-force-prune
Fixes #10908: Preserve in-use boxes when force flag is used with prune
2019-09-06 08:49:40 -07:00
Brian Cain 09af983caa
Fixes #11051: Only use host vm if specified
Prior to this commit, the docker login action assumed that if there was
a password to authenticate with, Vagrant was using a host vm to run
docker. This is likely due to some legacy decisions with how Vagrant
used to manage running docker. This commit fixes that by only grabbing a
host_vm lock if the host_vm is actually in use, otherwise login
normally.
2019-09-05 14:54:40 -07:00
Brian Cain e19f54457d
Fixes #10908: Preserve in-use boxes when force flag is used with prune
Prior to this commit, `vagrant box prune --force` would not prompt a
user to prune Vagrant boxes, even if that box was in use. There was no
way to prune boxes, ignore the prompt, but keep in-use boxes. This
commit adds a new flag that can be combined with `--force`, that will
keep in-use boxes but prune older boxes without prompting the user.
2019-09-04 15:54:11 -07:00
Brian Cain e56d2581ee
Add before/after all tests 2019-08-27 14:36:36 -07:00
Brian Cain 271d427c57
Fix bug in :each provisioner sorting
Ensure each provisioners are properly inserted into the final
provisioner array
2019-08-27 14:28:06 -07:00
Ladar Levison 5fb9edd67b Functional/working unit tests for the alt linux guest plugin change hostname capability. 2019-08-27 23:00:36 +05:30
Ladar Levison 243ae0f368 Added service command to alt guest test. 2019-08-27 21:07:58 +05:30
Ladar Levison 0671843ec0 Initial alt guest unit test attempt. 2019-08-27 20:31:12 +05:30
Brian Cain c189e4d255
Redo how each provisioners are sorted 2019-08-26 16:05:02 -07:00
Brian Cain 28ef368881
Begin to add tests for mixin provisioner 2019-08-26 12:03:36 -07:00
Dan Čermák eb9b478951
Add ipv6 network config templates for SUSE based distributions 2019-08-09 17:23:46 +02:00
Tim Schumacher a7f09f010c alpine: Convert nfs_client capability to seperate commands
The workaround for the broken repository should be safe to be removed,
since the last affected Alpine version (<=3.3) EOL'd in November of 2017.

The remaining important commands can be split out into seperate calls
of sudo(), which removes the need for manual exit-code checking
(since it aborts by itself when a command fails) and makes the code
easier to handle in general.
2019-07-26 08:31:12 +02:00
Tim Schumacher 29362d8af4 alpine: Wire up tests 2019-07-18 03:36:50 +02:00
Tim Schumacher fbffb41fc4 guests: Add unmodified alpine support plugin from maier
This has been available as `vagrant-alpine` in the plugin
repository so far.
2019-07-18 03:35:40 +02:00
Chris Roberts 7fbe8bcabc Fix plugin discovery loading when no data directory is available
If the local data directory is unavailable, there will be no local
file to use within the plugin manager. Check for local file before
returning result, otherwise just return an empty hash.
2019-06-21 11:15:39 -07:00
Chris Roberts 7c6b2963c3
Merge pull request #10911 from chrisroberts/f-plugin-loading
Support loading machine configuration without provider validation
2019-06-20 11:23:10 -07:00
Chris Roberts fef8316b3c
Merge pull request #10915 from laozc/fix-gp
Fix provider name not work when specified
2019-06-20 11:22:01 -07:00
Brian Cain 181e356a23
Merge pull request #10917 from briancain/chef-install-check-update
Fixes #10912: Update chef install check for guests
2019-06-20 08:11:50 -07:00
Chris Roberts 5e0f64d654 Only run tests that require bsdtar if it is available 2019-06-19 15:29:55 -07:00
Chris Roberts 2f2d1f9cb2 Fix docker test to not call docker executable 2019-06-19 11:59:09 -07:00
Brian Cain d55f8d3496
Fixes #10912: Update chef install check for guests
Prior to this commit, the chef_installed capability was looking for a
string that has recently changed in newer versions of chef. This commit
fixes that by instead just looking for the right version that was
configured for the chef client, rather than the specific string that
could change again in the future.
2019-06-17 11:02:57 -07:00
Brian Cain 75d42fed9d
Merge pull request #10902 from briancain/fixup-rsync-listener
Fixes #10895: Use relative paths to machines folder path for Listener
2019-06-17 08:20:37 -07:00
Zhongcheng Lao caae214bf7 Fix provider name not work when specified
Provider name should be symbol in guess_provider.
2019-06-17 08:22:50 +08:00