kafka-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ij...@apache.org
Subject kafka git commit: KAFKA-4251: fix test driver not launching in Vagrant 1.8.6
Date Tue, 07 Mar 2017 00:03:21 GMT
Repository: kafka
Updated Branches:
  refs/heads/0.10.0 88db95c57 -> 8814c2118


KAFKA-4251: fix test driver not launching in Vagrant 1.8.6

custom ip resolver in test driver makes incorrect assumption when calling vm.communicate.execute,
causing driver to fail launching with Vagrant 1.8.6, due to https://github.com/mitchellh/vagrant/pull/7676

Author: Xavier Léauté <xavier@confluent.io>

Reviewers: Ewen Cheslack-Postava <ewen@confluent.io>

Closes #1962 from xvrl/fix-vagrant-resolver


Project: http://git-wip-us.apache.org/repos/asf/kafka/repo
Commit: http://git-wip-us.apache.org/repos/asf/kafka/commit/8814c211
Tree: http://git-wip-us.apache.org/repos/asf/kafka/tree/8814c211
Diff: http://git-wip-us.apache.org/repos/asf/kafka/diff/8814c211

Branch: refs/heads/0.10.0
Commit: 8814c2118304ec914d9c4547c5af7115f2f813eb
Parents: 88db95c
Author: Xavier Léauté <xavier@confluent.io>
Authored: Tue Oct 4 14:45:09 2016 -0700
Committer: Ismael Juma <ismael@juma.me.uk>
Committed: Tue Mar 7 00:03:08 2017 +0000

----------------------------------------------------------------------
 Vagrantfile | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kafka/blob/8814c211/Vagrantfile
----------------------------------------------------------------------
diff --git a/Vagrantfile b/Vagrantfile
index 0471a7e..09d780c 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -99,9 +99,11 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
       if !cached_addresses.has_key?(vm.name)
         state_id = vm.state.id
         if state_id != :not_created && state_id != :stopped && vm.communicate.ready?
-          vm.communicate.execute("/sbin/ifconfig eth0 | grep 'inet addr' | tail -n 1 | egrep
-o '[0-9\.]+' | head -n 1 2>&1") do |type, contents|
-            cached_addresses[vm.name] = contents.split("\n").first[/(\d+\.\d+\.\d+\.\d+)/,
1]
+          contents = ''
+          vm.communicate.execute("/sbin/ifconfig eth0 | grep 'inet addr' | tail -n 1 | egrep
-o '[0-9\.]+' | head -n 1 2>&1") do |type, data|
+            contents << data
           end
+          cached_addresses[vm.name] = contents.split("\n").first[/(\d+\.\d+\.\d+\.\d+)/,
1]
         else
           cached_addresses[vm.name] = nil
         end


Mime
View raw message