Difference between revisions of "SuiteCRM App Migration"

From Univention Wiki

Jump to: navigation, search
(Created page with "Category:App Center Category:Docker App Migration '''Work in Progress''' Starting with version 7.6.3-2 the SuiteCRM App for UCS is available as Docker App...")
(No difference)

Revision as of 13:34, 24 November 2016

Work in Progress

Starting with version 7.6.3-2 the SuiteCRM App for UCS is available as Docker App. New installations automatically using this Docker App.

To update an existing non-Docker SuiteCRM App to the new Docker SuiteCRM App a manual migration has to be done. Basically, SuiteCRM on the server (Docker host) is removed and installed in a new Docker container. Directories with SuiteCRM data are mapped into the container and the container continues to use the database on the Docker host.

The following steps are necessary to migrate the non-Docker SuiteCRM App to Docker:

Save settings and prepare SuiteCRM App removal

mkdir -p /var/lib/suitecrm
mv /var/www/suitecrm /var/lib/suitecrm/
cp /etc/suitecrm/db.secret /etc/mysql-digitec-suitecrm.secret
rm /usr/share/suitecrm/uninstall-suitecrm.sh
rm /usr/lib/univention-uninstall/79suitecrm-web-uninstall.uinst

Remove SuiteCRM App

univention-app remove digitec-suitecrm
a2dissite suitecrm
invoke-rc.d apache2 restart
. /usr/share/univention-join/joinscripthelper.lib
joinscript_remove_script_from_status_file suitecrm-web

Install SuiteCRM Docker App

echo "digitec-suitecrm v2 successful" >> /usr/lib/univention-install/.index.txt
mysql --no-defaults -u root -h localhost --password="$(< /etc/mysql.secret)"<<EOF
GRANT ALL PRIVILEGES ON suitecrm.* TO 'suitecrm'@'%' IDENTIFIED BY '$(</etc/mysql-digitec-suitecrm.secret)';
ucr unset  appcenter/prudence/docker/digitec-suitecrm
univention-app install digitec-suitecrm

univention-app shell digitec-suitecrm ucr commit /etc/apache2/sites-available/suitecrm
univention-app shell digitec-suitecrm a2ensite suitecrm
univention-app shell digitec-suitecrm invoke-rc.d apache2 restart
univention-app shell digitec-suitecrm bash -c 'sed -i "s/\(.*db_host_name.*\)localhost\(.*\)/\1$DB_HOST\2/" /var/www/suitecrm/config.php'

Further configurations or modifications of UCR settings have to be done in the container from now on. Use the following command to change into the new Tine20 App container:

univention-app shell digitec-suitecrm
Personal tools