From 7e79d593659b3e520ba32a9fd372940c33f8d286 Mon Sep 17 00:00:00 2001 From: Fabio Rehm Date: Thu, 13 Mar 2014 09:42:39 -0300 Subject: [PATCH 1/3] core: Fix `vagrant ssh` [GH-252] --- lib/vagrant-lxc/action.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/vagrant-lxc/action.rb b/lib/vagrant-lxc/action.rb index ce53061..ad72314 100644 --- a/lib/vagrant-lxc/action.rb +++ b/lib/vagrant-lxc/action.rb @@ -218,7 +218,7 @@ module Vagrant next end - b3.use BuiltIn::SSHExec + b3.use Builtin::SSHExec end end end From 5b24cf61360dd2a9ae4c3069393d04ed48c0a2e2 Mon Sep 17 00:00:00 2001 From: Fabio Rehm Date: Thu, 13 Mar 2014 10:33:37 -0300 Subject: [PATCH 2/3] Add section about Vagrant 1.5 compatibility --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 241dc34..dc8c757 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,13 @@ to see it in action. latest stable version of the plugin, please check the [0.8-stable](https://github.com/fgrehm/vagrant-lxc/tree/0.8-stable) branch. +## Usage with Vagrant 1.5 + +Usage with the recently released Vagrant 1.5 is only possible by [building the +plugin from sources](https://github.com/fgrehm/vagrant-lxc/wiki/Development#wiki-installing-the-plugin-from-source). +The 1.0.0.beta1 version of the plugin that will ship with the changes required +is expected to be released by the end of March 2014. + ## Features From be12f11cedafb77e837e876e355dd82052cdf766 Mon Sep 17 00:00:00 2001 From: Franz Pletz Date: Thu, 13 Mar 2014 18:10:50 +0100 Subject: [PATCH 3/3] Set container utsname to configured hostname per default Previously, the utsname of a machine was set to the vagrant machine ID. As the utsname represents the hostname of the machine and is independent from the name of the actual LXC container, the hostname that was specified in the Vagrantfile should be used instead. If no hostname is provided, the machine ID will be used like before. Additionally, this will trigger the DHCP client in the container to send the correct hostname to the DHCP server on the first request at boot. Vagrant sets the configured hostname only after the network is up. If for example automatic DNS updates are configured, the right DNS record will be created every time. --- lib/vagrant-lxc/action/boot.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/vagrant-lxc/action/boot.rb b/lib/vagrant-lxc/action/boot.rb index e6b162b..036470d 100644 --- a/lib/vagrant-lxc/action/boot.rb +++ b/lib/vagrant-lxc/action/boot.rb @@ -11,7 +11,8 @@ module Vagrant config = env[:machine].provider_config - config.customize 'utsname', env[:machine].id + config.customize 'utsname', + env[:machine].config.vm.hostname || env[:machine].id env[:ui].info I18n.t("vagrant_lxc.messages.starting") env[:machine].provider.driver.start(config.customizations)