Fixed it so the installation runs to the end automatically, no more race condition.
Vagrant can now write to configuration.xml and thereby alllowing vagrant to run the OpenGrok index on source.