Well, am poking around with CENTOS 7 currently, and i wanted to clone an existing server, for backup purpose. The database from live server has been set to collation utf8_general_ci and after cloning it is latin1_swedish_ci, which is the standard collation from MySQL (or MariaDB it seems). Why wouldn't latest virtualmin under CENTOS 7 use the existing utf8_general_ci collation while cloning the virtual server?
And, any chance to add commands to be executed AFTER cloning?
Most applications have their own config file, and after cloning it would still point to the old database and link setting. Therefore it would make sense, executing a post-clone script, to change this settings. My strategy is, that i usually have a example.com host and clone it to clone1.example.com. For this i create a config file, which would have adapted mysql credentials and the new base link being set. Now i have to copy this each time i create a clone; which sometimes i forget, so in the end, i am doing something on the clone, but change the database of example.com, which wasn't my intention. Of course, there could be other commands to be run as well. My application also requires a specific cron job to be set in crontab, and the cronjob has to be restarted after changing crontab etc. You get the idea.
So any idea how to manage that?