Init script for Jackrabbit in a Vagrant box (tested on Ubuntu trusty only). I am not an advanced bash developer, so don't hesitate to contribute!
Copy this script in your /etc/init.d directory:
sudo cp [ script ] /etc/init.d/jackrabbit
Adapt the content of the header (the first variables) to fit your needs. Test your script:
sudo service jackrabbit start
sudo service jackrabbit status
sudo service jackrabbit stop
Then activate the service at startup
sudo update-rc.d jackrabbit defaults
Enjoy ;)