I'am just starting with magnolia and at the very beginning it surprised me that Magnolia needs to be installed after each .war deploy to tomcat. I do some changes in my project, deploy it with mvn tomcat7:deploy/redeploy
. Tomcat automatically recognise that ROOT.war
has changed so it unpack it automatically and after that when I'm entering localhost:8080
it wants me to install Magnolia modules again. Is it really necessary to install all modules again and again after every single changes in my project and deploy? Maybe the way how I'm making changes in my project and deploying it is wrong? If I'am not mistaken in that way my content changes also will be overwritten/deleted?
You have to re-install Magnolia every time because I think that you delete your repository (database) every time that you deploy a new version.
Probably you are saving your data in a folder inside webapps and every time that you deploy a new .war it is deleted.
If you want to keep your website and modules between deployments, I need to change the repository location to a different folder in the file system, or set a db connection.
You can do that by modifying the repositories.xml file or adding a custom jackrabbit conf file, in this article you will find a lot of useful info, and I suggest you to have a look into the paragraph 'Custom Jackrabbit configuration file'