Skip to content

Instantly share code, notes, and snippets.

@jlawsonb
Forked from phindmarsh/Vagrantfile
Created November 18, 2015 21:20
Show Gist options
  • Save jlawsonb/bd540963eaa510d15991 to your computer and use it in GitHub Desktop.
Save jlawsonb/bd540963eaa510d15991 to your computer and use it in GitHub Desktop.
NFS issue when using Vagrant and Docker
host:$ vagrant up --provider=docker
Bringing machine 'api' up with 'docker' provider...
==> api: Docker host is required. One will be created if necessary...
api: Docker host VM is already ready.
==> api: Syncing folders to the host VM...
No host IP was given to the Vagrant core NFS helper. This is
an internal error that should be reported as a bug.
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.provider "docker" do |d|
d.vagrant_vagrantfile = "./Vagrantfile.proxy"
end
config.vm.define "container" do |v|
v.vm.provider "docker" do |d|
d.name = "some-container"
d.build_dir = "./container"
end
v.vm.synced_folder "./nfs-share",
"/shared",
type: "nfs"
end
end
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "hashicorp/precise64"
config.vm.provider "virtualbox"
config.vm.provision "docker"
config.vm.provision "shell", inline:
"ps aux | grep 'sshd:' | awk '{print $2}' | xargs kill"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment