guests/redhat: fix network configuration in CentOS 5
ip command is not on PATH by default in CentOS 5 so call it with the full path.
This commit is contained in:
parent
01fd5c1dd1
commit
de9abc8f72
|
@ -35,7 +35,7 @@ module VagrantPlugins
|
|||
interfaces = []
|
||||
commands = []
|
||||
|
||||
comm.sudo("ip -o -0 addr | grep -v LOOPBACK | awk '{print $2}' | sed 's/://'") do |_, stdout|
|
||||
comm.sudo("/sbin/ip -o -0 addr | grep -v LOOPBACK | awk '{print $2}' | sed 's/://'") do |_, stdout|
|
||||
interfaces = stdout.split("\n")
|
||||
end
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ describe "VagrantPlugins::GuestRedHat::Cap::ConfigureNetworks" do
|
|||
|
||||
before do
|
||||
allow(machine).to receive(:communicate).and_return(comm)
|
||||
comm.stub_command("ip -o -0 addr | grep -v LOOPBACK | awk '{print $2}' | sed 's/://'",
|
||||
comm.stub_command("/sbin/ip -o -0 addr | grep -v LOOPBACK | awk '{print $2}' | sed 's/://'",
|
||||
stdout: "eth1\neth2")
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue