I use Vagrant boxes for a number of projects and I've had no problem until this. To help my documentation crew I setup MkDocs with Vagrant and everything works up to the point I want to browser from the host.
I use scotch/box 3.5 free version, Python 2.7.12
, I've installed pip 18.1
and I start sudo mkdocs serve
. I know it's working because I can curl http://127.0.0.1:8000
but when I browse on the host http://192.168.33.10:8000/
returns
This site can’t be reached 192.168.33.10 refused to connect.
Search Google for 192 168 8000
ERR_CONNECTION_REFUSED
Browsing http://192.168.33.10
will return Scotch IO box's /public/index.php
I also tried shutting down the box's apache server but that didn't help either. Does anyone see what is incorrect in my setup?
Vagrantfile
Vagrant.configure("2") do |config|
# /*=====================================
# = FREE VERSION! =
# =====================================*/
# This is the free (still awesome) version of Scotch Box.
# Please go Pro to support the project and get more features.
# Check out https://box.scotch.io to learn more. Thanks
config.vm.box = "scotch/box"
config.vm.network "private_network", ip: "192.168.33.10"
config.vm.network "forwarded_port", guest: 8000, host: 8000
config.vm.hostname = "scotchbox"
config.vm.synced_folder ".", "/var/www", :mount_options => ["dmode=777", "fmode=666"]
# Optional NFS. Make sure to remove other synced_folder line too
#config.vm.synced_folder ".", "/var/www", :nfs => { :mount_options => ["dmode=777","fmode=666"] }
config.vm.provision "shell", path: "deploy.sh"
end
deploy.sh #!/usr/bin/env bash
apt-get update
apt-get install -y python-pip
pip install mkdocs
UPDATE
I can see the MkDocs
is running and detects changes to the source files.
Servers running on the box.