I want to use monit to monitor services on my Ubuntu VM(precise 32) but I cannot access the monit daemon via HTTP from the host (local) machine.
I have enabled the following settings in /etc/monit/monitrc:
set httpd port 2812 and
use address localhost
allow localhost
allow vagrant:vagrant_pwd
and have forwarded port 2812 in the virtual machine to host machine in Vagrantfile as follows:
config.vm.forward_port 2812, 2812
I have confirmed that monit is running on the virtual machine by ssh'ing into the VM and running:
sudo /etc/init.d/monit status
and can access the Monit daemon using HTTP within the VM by running
curl -u vagrant:vagrant localhost:2812
but when I enter localhost:2812 on the host machine browser (firefox) I get no response.
Any ideas on how to make this work?