Commit Graph

577 Commits

Author SHA1 Message Date
Martin André
41f16c9b59 Handle private networks with type DHCP
Closes #427
2015-09-23 22:24:44 +09:00
Dmitry Vasilets
d2f96f56f6 Merge pull request #457 from timhughes/management_network_mac
Enables setting of MAC address on management interface as per #426
2015-09-18 08:26:25 +02:00
Tim Hughes
e904fd8941 Enables setting of MAC address on management interface as per #426 2015-09-14 17:37:19 +01:00
Dmitry Vasilets
4a8b88fc87 Merge pull request #455 from skamithi/mcast_and_tcp_tunnel_support
UDP/TCP/Mcast tunnel support for point-2-point VM connections
2015-09-09 08:52:03 +02:00
stanley karunditu
17254d4358 previously in PR#413 added tcp tunnel support. adding mcast tunnel support
and merging features and just calling it tunnel support.
2015-09-08 14:11:05 -04:00
Dmitry Vasilets
8985fbd494 Merge pull request #446 from dustymabe/master
A few spelling/wording enhancements.
2015-08-25 16:52:56 +02:00
Dusty Mabe
6bbb16fc34 A few spelling/wording enhancements. 2015-08-25 10:44:16 -04:00
Dmitry Vasilets
454bc78688 Merge pull request #442 from infernix/box_optional
Make boxes optional and move boot ordering into a separate class
2015-08-15 01:01:04 +02:00
Gerben Meijer
3b641cc5cc Update docs: no box requires vagrant 1.6.0+ 2015-08-14 14:33:01 +02:00
Gerben Meijer
aa3a6faf44 Implement boot ordering as a separate class
This is required because in current versions of libvirt, it is not
possible to specify a boot order when attaching a device; therefore we
can only parse the entire domain XML after all devices have been created
and then assign boot ordering according to the Vagrantfile
specification. This allows us to specify exact boot order for hd, cdrom
and network.
2015-08-11 00:39:53 +02:00
Gerben Meijer
bbbd804f28 Add support for VMs with no box
Vagrant already supports VMs without boxes with Docker.
We leverage this in libvirt as well. The use case for this is to PXE
oot a vagrant VM that is then installed over the network then
installed over the network; a different use case would be to test PXE
booted clients that do not use a hard drive whatsoever.
2015-08-10 17:10:23 +02:00
Gerben Meijer
262e8eed59 Revert "Use per device boot order when boot_order is set"
This reverts commit dc2f5cb4aa.
2015-08-10 17:07:20 +02:00
dima
b50b23283b Merge branch 'master' of https://github.com/gbriones1/vagrant-libvirt into gbriones1-master 2015-08-07 08:33:21 +02:00
Gabriel Briones Sayeg
f634f4370b Merge branch 'master' of https://github.com/gbriones1/vagrant-libvirt 2015-08-06 11:01:09 -05:00
Gabriel Briones Sayeg
3277506627 Include custom UEFI loader
Domain XML has loader tag to read specific OVMF.fd path

Signed-off-by: Gabriel Briones Sayeg <gbriones.gdl@gmail.com>
2015-08-06 11:00:15 -05:00
dima
be0a8bc390 typo.thanks rubocop 2015-08-05 21:57:26 +02:00
Dmitry Vasilets
0c1c94bf36 Merge pull request #436 from electrofelix/parallel-ssh_info
allow query of ssh_info in parallel from other machines or user
2015-08-05 21:48:13 +02:00
dima
e576903680 typo 2015-08-05 21:45:53 +02:00
Dmitry Vasilets
e7450a6723 Merge pull request #440 from d0c-s4vage/feature-inputs
Added ability to specify inputs for the VM via the Vagrantfile
2015-08-05 21:43:31 +02:00
talus
959668075a inputs work now 2015-08-05 14:07:46 -05:00
James Johnson
a4e2730fa7 added inputs to the environment helper 2015-08-05 14:00:55 -05:00
James Johnson
de421b1be1 readme changes 2015-08-05 10:49:12 -05:00
James Johnson
1a8e457960 merged in the upstream changes correctly (I hope) 2015-08-05 10:47:58 -05:00
James Johnson
57e2f9e77c soft tabs... 2015-08-05 10:38:35 -05:00
James Johnson
d82c1a3f95 Can now specify inputs for the VM. E.g.
```ruby
Vagrant.configure("2") do |config|
  config.vm.provider :libvirt do |libvirt|
    # very useful when having mouse issues when viewing VMs via VNC
    libvirt.input :type => "tablet", :bus => "usb"
  end
end
```
2015-08-05 10:37:19 -05:00
Gabriel Briones Sayeg
71ca7cab1f Include custom UEFI loader
Domain XML has loader tag to read specific OVMF.fd path

Signed-off-by: Gabriel Briones Sayeg <gbriones.gdl@gmail.com>
2015-08-03 16:24:55 -05:00
Dmitry Vasilets
cc28c54a0f Merge pull request #433 from electrofelix/enable-travis
Enable travis CI testing of github PRs
2015-08-01 09:32:20 +02:00
Dmitry Vasilets
63ac8dfdca Merge pull request #432 from electrofelix/fix-logging
Ensure correct order of logger creation
2015-07-31 21:57:51 +02:00
Dmitry Vasilets
8f9fac8da9 Merge pull request #437 from electrofelix/add-cleanup-action
Enable provisionser cleanup hooks to be actioned
2015-07-31 21:53:43 +02:00
Darragh Bailey
edf730e9f5 Enable provisionser cleanup hooks to be actioned
Call the builtin ProvisionserCleanup action when destroying machines.
Part of vagrant since version 1.3.0.
2015-07-31 20:48:19 +01:00
Darragh Bailey
efeb6c6b8a Allow shutting-down state to be returned
If the machine is in a shutting-down state, simply return this instead
of waiting until the machine has reached a steady state.
2015-07-31 09:31:52 +01:00
Darragh Bailey
e7dec9acc3 Condense state description retrieval
Reduce state description retrieval to keying off the state id and use a
simple substitution for the short name of the same.
2015-07-31 09:31:52 +01:00
Darragh Bailey
cee934a482 Remove machine ssh_info and state from using actions
Remove the ReadSSHInfo and ReadState actions and corresponding calls to
dispatch queries by vagrant on the provider for current `ssh_info` and
`state` to be handled by actions. Change the corresponding methods added
to the Driver and Provider classes to avoid modifying `machine.id`
directly and allow vagrant to take care of resetting it whenever `state`
returns :not_created.

This ensures that both `ssh_info` and `state` may be called by other
threads, such as the ansible provisioner building the inventory file,
on machines without causing exceptions due to machine locks preventing
modification (setting `machine.id` to nil) and Batch locking preventing
multiple sets of actions being executed on the same machine by
different threads/processes.

Follows the design of the in-tree docker provider for vagrant.
2015-07-31 09:31:52 +01:00
Darragh Bailey
db440907f7 Move libvirt connection setup to driver
Handle libvirt connection through a driver located within the provider
so it can be reached via the machine settings. Adopt the format followed
by the docker/virtualbox providers as this is likely to remain well
supported.

Will allow queries to be made without needing to setup a specific action
which is important when dealing with parallel machine provisioning.
Calling actions from other threads to retrieve information on the state
of the other running machines currently will cause vagrant to complain
about the machine being locked.
2015-07-31 09:31:52 +01:00
Darragh Bailey
4c7a0d5db0 Enable travis CI testing of github PRs
Add travis CI and support testing against a matrix of vagrant versions.
2015-07-29 17:44:23 +01:00
Darragh Bailey
1f45c5a788 Ensure correct order of logger creation
Loggers must be defined in the correct heirarchial order to ensure that
child loggers inherit the level defined on the parent logger. Otherwise
need to traverse the entire tree to modify the level.
2015-07-29 17:23:16 +01:00
Dmitry Vasilets
a46545e66c Merge pull request #425 from infernix/boot-order
Use per device boot order when boot_order is set
2015-07-29 13:42:38 +02:00
Gerben Meijer
f47cb7c98b Describe changes to boot process due to boot order 2015-07-29 13:31:07 +02:00
Gerben Meijer
dc2f5cb4aa Use per device boot order when boot_order is set
This allows for network boot with any of the NICs that are defined instead of
only from the primary NIC.
2015-07-24 15:25:47 +02:00
Dmitry Vasilets
fd4efde95e Merge pull request #422 from grahamhayes/master
Really Limit p9 tag to 31 bytes
2015-07-23 08:00:49 +02:00
Dmitry Vasilets
5c65625fe8 Merge pull request #423 from anduslim/master
Ensure IP is a string and not an array before connecting via UDP socket.
2015-07-23 07:59:38 +02:00
Andus Lim
d90da43f85 Ensure IP is a string and not an array before connecting via UDP socket. 2015-07-23 10:05:22 +08:00
Graham Hayes
4dd13bf219 Really Limit p9 tag to 31 bytes
Libvirt p9 file system passthrough requires the tag be less than
31 bytes. Using the mount point as the tag can easily exceed this.

In KVM passthough the "target" attribuite in the XML is acutally the
mount tag.

Fixed the mounting script to use the same MD5 to mount the right
filesystem

Fixes #323
2015-07-21 15:45:43 +01:00
Dmitry Vasilets
c834ba3285 Merge pull request #417 from joejulian/allow_veryisolated_networks
Allow veryisolated networks
2015-07-21 08:40:13 +02:00
Joe Julian
fc24db479f Make lookup_network_by_name the default for veryisolated networks 2015-07-20 13:01:34 -07:00
Joe Julian
9b7c9def3c Removed comment
Vagrant only requires an ip **if** `type` is set **and** is not `dhcp`. The
only other type, currently, is `nfs`. Obviously nfs requires an IP so under
that circumstance or if `type` is set to anything but dhcp, vagrant will
error if an ip is not assigned.

If `type` is `nil`, it is deleted from the hash.
2015-07-17 17:23:32 -07:00
Joe Julian
546c98c0a2 Allow veryisolated networks without IP
* Moved network lookup by IP to `lookup_network_by_ip`
* Lookup by name only if lookup by ip fails *and* forward_mode is
  `veryisolated`. This will preserve existing functionality.
* Added network creation ability to `handle_network_name_option`
** Network **must** be veryisolated to be created by name
** Network **must not** have an ip address to be used in the
   `handle_network_name_option` path.

Minor changes:
* corrected inverted autostart logic
* screen formatting

Fixes #402
2015-07-17 17:23:19 -07:00
Joe Julian
6d8c45542e Select the network by name 2015-07-17 15:31:17 -07:00
Joe Julian
6083b613d9 Merge remote-tracking branch 'upstream/master' into allow_veryisolated_networks 2015-07-17 15:21:42 -07:00
Dmitry Vasilets
911966c8b4 Merge pull request #421 from electrofelix/parallel-ssh_info
Allow read actions to be called by other machines
2015-07-15 16:50:14 +02:00