[DRE-commits] [vagrant-libvirt] 38/104: v0.0.5
Antonio Terceiro
terceiro at moszumanska.debian.org
Sun Apr 24 13:55:42 UTC 2016
This is an automated email from the git hooks/post-receive script.
terceiro pushed a commit to annotated tag 0.0.11
in repository vagrant-libvirt.
commit 29daa532c6066a2eda722ff3649cda8ee62aec41
Author: pradels <les.pradels at gmail.com>
Date: Fri May 10 15:11:13 2013 +0200
v0.0.5
---
CHANGELOG.md | 9 ++++++
README.md | 68 ++++++++++++++++++++++++++++++++++--------
lib/vagrant-libvirt/version.rb | 2 +-
3 files changed, 65 insertions(+), 14 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index b312efe..1b32848 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,12 @@
+# 0.0.5 (May 10, 2013)
+
+* Private networks support.
+* Creating new private networks if ip is specified and network is not
+ available.
+* Removing previously created networks, if there are no active connections.
+* Guest interfaces configuration.
+* Setting guest hostname (via `config.vm.hostname`).
+
# 0.0.4 (May 5, 2013)
* Bug fix in number of parameters for provisioner.
diff --git a/README.md b/README.md
index 35dca08..e75f3f0 100644
--- a/README.md
+++ b/README.md
@@ -4,16 +4,19 @@ This is a [Vagrant](http://www.vagrantup.com) 1.1+ plugin that adds an
[Libvirt](http://libvirt.org) provider to Vagrant, allowing Vagrant to
control and provision machines via Libvirt toolkit.
-**Note:** Actual version (0.0.4) is still a development one. Feedback is
+**Note:** Actual version (0.0.5) is still a development one. Feedback is
welcome and can help a lot :-)
-## Features (Version 0.0.4)
+## Features (Version 0.0.5)
+* Controll local or remote Libvirt hypervisors.
* Vagrant `up`, `destroy`, `suspend`, `resume`, `halt`, `ssh` and `provision` commands.
* Upload box image (qcow2 format) to Libvirt storage pool.
* Create volume as COW diff image for domains.
+* Create private networks.
* Create and boot Libvirt domains.
* SSH into domains.
+* Setup hostname and network interfaces.
* Provision domains with any built-in Vagrant provisioner.
* Minimal synced folder support via `rsync`.
@@ -31,7 +34,7 @@ installing, `vagrant up` and specify the `libvirt` provider. An example is shown
$ vagrant plugin install vagrant-libvirt
```
-### Possible problems with plugin installation
+### Possible problems with plugin installation on Linux
In case of problems with building nokogiri and ruby-libvirt gem, install
missing development libraries for libxslt, libxml2 and libvirt.
@@ -57,26 +60,27 @@ want. This is just an example of Libvirt CentOS 6.4 box available:
$ vagrant box add centos64 http://kwok.cz/centos64.box
```
-And then make a Vagrantfile that looks like the following, filling in
-your information where necessary.
+And then make a Vagrantfile that looks like the following, filling in your
+information where necessary. In example below, VM named test_vm is created from
+centos64 box and setup with 10.20.30.40 IP address.
```ruby
Vagrant.configure("2") do |config|
config.vm.define :test_vm do |test_vm|
test_vm.vm.box = "centos64"
+ test_vm.vm.network :private_network, :ip => '10.20.30.40'
end
config.vm.provider :libvirt do |libvirt|
libvirt.driver = "qemu"
- libvirt.host = "example.com"
+ libvirt.host = "localhost"
libvirt.connect_via_ssh = true
libvirt.username = "root"
libvirt.storage_pool_name = "default"
- libvirt.nested = true
end
end
-
```
+
### Libvirt Configuration Options
This provider exposes quite a few provider-specific configuration options:
@@ -93,7 +97,7 @@ This provider exposes quite a few provider-specific configuration options:
* `memory` - Amount of memory in MBytes. Defaults to 512 if not set.
* `cpus` - Number of virtual cpus. Defaults to 1 if not set.
-* `nested` - [Enable nested virtualization.Default: false] (https://github.com/torvalds/linux/blob/master/Documentation/virtual/kvm/nested-vmx.txt)
+* `nested` - [Enable nested virtualization](https://github.com/torvalds/linux/blob/master/Documentation/virtual/kvm/nested-vmx.txt). Default is false.
Specific domain settings can be set for each domain separately in multi-VM
environment. Example below shows a part of Vagrantfile, where specific options
@@ -109,7 +113,7 @@ Vagrant.configure("2") do |config|
end
end
- ...
+ # ...
```
## Create Project - Vagrant up
@@ -141,9 +145,47 @@ Vagrant goes through steps below when creating new project:
## Networks
-Networking features in the form of `config.vm.network` are not supported right
-now. Support for private network is planned to be added in next release of
-provider.
+Networking features in the form of `config.vm.network` support private networks
+concept. No public network or port forwarding are supported in current version
+of provider.
+
+An examples of network interface definitions:
+
+```ruby
+ config.vm.define :test_vm1 do |test_vm1|
+ test_vm1.vm.network :private_network, :ip => '10.20.30.40'
+ end
+```
+
+In example below, one network interface is configured for VM test_vm1. After
+you run `vagrant up`, VM will be accessible on IP address 10.20.30.40. So if
+you install a web server via provisioner, you will be able to access your
+testing server on http://10.20.30.40 URL. But beware that this address is
+private to libvirt host only. It's not visible outside of the hypervisor box.
+
+If network 10.20.30.0/24 doesn't exist, provider will create it. By default
+created networks are NATed to outside world, so your VM will be able to connect
+to the internet (if hypervisor can). And by default, DHCP is offering addresses
+on newly created networks.
+
+### Private Network Options
+
+There is a way to pass specific options for libvirt provider when using
+`config.vm.network` to configure new network interface. Each parameter name
+starts with 'libvirt__' string. Here is a list of those options:
+
+* `:libvirt__network_name` - Name of libvirt network to connect to. By default,
+ network 'default' is used.
+* `:libvirt__netmask` - Used only together with `:ip` option. Default is
+ '255.255.255.0'.
+* `:libvirt__nat_interface` - Name of interface, where should network be
+ NATed. Used only when creating new network. By default, all physical
+ interfaces are used.
+* `:libvirt__isolated` - If network should be isolated - without NAT to outside.
+ Used only when creating new network. Default is set to false.
+* `:libvirt__dhcp_enabled` - If DHCP will offer addresses, or not. Used only
+ when creating new network. Default is true.
+* `:libvirt__adapter` - Number specifiyng sequence number of interface.
## Obtaining Domain IP Address
diff --git a/lib/vagrant-libvirt/version.rb b/lib/vagrant-libvirt/version.rb
index a0b7666..e159d41 100644
--- a/lib/vagrant-libvirt/version.rb
+++ b/lib/vagrant-libvirt/version.rb
@@ -1,5 +1,5 @@
module VagrantPlugins
module Libvirt
- VERSION = "0.0.4"
+ VERSION = "0.0.5"
end
end
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/vagrant-libvirt.git
More information about the Pkg-ruby-extras-commits
mailing list