I'm having a hard time with a Docker container I am trying to run in a
vagrant/libvirt vm. (To be specific, it's the official Tensorflow
container, with py3 and gpu and jupyter support).
Here is the relevant fragment of my Vagrant file:
authToken = SecureRandom.hex
host.vm.provision :docker do |docker|
docker.run "tensorflow/tensorflow",
image: "tensorflow/tensorflow:latest-gpu-py3-jupyter",
args: "-it -u 1000:1000 -p 8080:8888 -v /tf:/tf",
cmd: "/bin/bash -c \"source /etc/bash.bashrc && jupyter notebook
--no-browser --ip=0.0.0.0 --allow-root --NotebookApp.token='#{authToken}'\""
end
If I vagrant up the relevant machine, it ends up printing out the authToken on
my screen, and then I can log in to the Jupyter server on port 8080. So far so
good.
But, there's a problem. Jupyter can't find the files in /tf.
On the other hand, if I go back to my virtual machine and stop the docker
container, I can run that "same" command (by hand) and Jupyter works and sees
the files. I can do this as either `vagrant` or `root`. Either one works
(though, to be fair, I put `vagrant` into my `docker` group in an earlier
provisioning step...)
So this tells me that somehow, Vagrant or Docker are treating the command
differently, based on how/when it's invoked. I am not sure what else to do, so
I figured I'd ask here and on stack exchange, before escalating to the github
issues page.
Any ideas?
Thanks,
Alex
--
This mailing list is governed under the HashiCorp Community Guidelines -
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of
those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vagrant-up/5c002747-81fc-40f0-97ae-fb45f4865176%40googlegroups.com.