From da61b8e7c976af3faeb719a98394f3a1aade6e55 Mon Sep 17 00:00:00 2001
From: Maxim Krasilnikov <mak.krasilnikov@gmail.com>
Date: Tue, 3 Oct 2017 13:32:19 +0300
Subject: [PATCH] Added workaround for vagrant 1.9 and centos vm box (#1738)

---
 Vagrantfile     | 8 +++++++-
 docs/vagrant.md | 2 +-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/Vagrantfile b/Vagrantfile
index c1e0d25a2..49325a601 100644
--- a/Vagrantfile
+++ b/Vagrantfile
@@ -3,7 +3,7 @@
 
 require 'fileutils'
 
-Vagrant.require_version ">= 1.8.0"
+Vagrant.require_version ">= 1.9.0"
 
 CONFIG = File.join(File.dirname(__FILE__), "vagrant/config.rb")
 
@@ -122,6 +122,12 @@ Vagrant.configure("2") do |config|
       }
 
       config.vm.network :private_network, ip: ip
+      
+      # workaround for Vagrant 1.9.1 and centos vm
+      # https://github.com/hashicorp/vagrant/issues/8096
+      if Vagrant::VERSION == "1.9.1" && $os == "centos"
+        config.vm.provision "shell", inline: "service network restart", run: "always"
+      end
 
       # Only execute once the Ansible provisioner,
       # when all the machines are up and ready.
diff --git a/docs/vagrant.md b/docs/vagrant.md
index 1b0073799..042e8137b 100644
--- a/docs/vagrant.md
+++ b/docs/vagrant.md
@@ -1,7 +1,7 @@
 Vagrant Install
 =================
 
-Assuming you have Vagrant (1.8+) installed with virtualbox (it may work
+Assuming you have Vagrant (1.9+) installed with virtualbox (it may work
 with vmware, but is untested) you should be able to launch a 3 node
 Kubernetes cluster by simply running `$ vagrant up`.<br />
 
-- 
GitLab