Live Helper Chat support forum.. Forum is locked. New place for questions - Github Discussions
You are not logged in.
Pages: 1
Hi,
We are currently on 2.13 version and have Automated-Hosting with some minor modifications.
I'd like to know the steps for updating the site to the newest version of AH.
Are these the correct general steps?
1. Update the main installation of LHC per the instructions as if Automated Hosting is not installed.
2. Update the Automated Hosting plugin with the newest version of Automated Hosting.
3. Copy the updated main installation over to the Automated Hosting customer folder as if re-installing
4. Update the configuration in the customer installation as described in the instructions below.
5. Restore any custom modifications.
Please review the following and let us know if anything is missing or not needed. Once reviewed, I'll update our server and post any issues found.
Thanks!
*******************
These are the PROPOSED/UNTESTED detailed instructions for updating Automated Hosting (modified from the install instructions).
Please correct, comment, or clarify the steps.
1. Update Live Helper Chat using the standard instructions https://livehelperchat.com/article/view/63
2. The settings for Automated Hosting in settings/settings.ini.php file under site section should already be updated from the original installation of Automated Hosting. No changes are needed
3. Extract the new version of "instance" extension to extension folder in the main installation
4. The extension should already be Active in LHC. Nothing to do but check that it is still configured.
'extensions' =>
array ('instance')
5. The extension should still be configured in var/autoloads/lhextension_autoload.php. If desired, check that it is still configured
And make it look like
return array(
'erLhcoreClassModelInstance' => 'extension/instance/classes/erlhcoreclassmodelinstance.php',
'erLhcoreClassInstance' => 'extension/instance/classes/erlhcoreclassinstance.php',
'erLhcoreClassInstanceDBMysql' => 'extension/instance/classes/dbhandlers/mysql.php',
'erLhcoreClassInstanceDBDirectAdmin' => 'extension/instance/classes/dbhandlers/directadmin.php',
'HTTPSocket' => 'extension/instance/classes/dbhandlers/httpsocket.php',
'erLhcoreClassModelInstanceInvoice' => 'extension/instance/classes/erlhcoreclassmodelinstanceinvoice.php',
);
6. No changes to cronjob are needed for this update.
7. Save a copy of var/autoloads/lhextension_autoload.php from the Automated Hosting folder. This is the folder created during the installation of AH which contains the copy of the LHC.
8. Save a copy of the settings.php file from the AH folder.
9. Copy the newly updated LHC installation and overwrite the instance of AH folder.
10. Delete from copied folder extension/instance
11. Restore the copy of var/autoloads/lhextension_autoload.php copied in step 7. Make sure it looks like this:
return array(
'erLhcoreClassModelInstance' => 'extension/instancecustomer/classes/erlhcoreclassmodelinstance.php',
'erLhcoreClassInstance' => 'extension/instancecustomer/classes/erlhcoreclassinstance.php',
'erLhcoreClassLazyDatabaseConfiguration' => 'extension/instancecustomer/classes/lhdb.php',
'erLhcoreClassModelInstanceInvoice' => 'extension/instancecustomer/classes/erlhcoreclassmodelinstanceinvoice.php'
);
12. Overwrite the instance customer with the new instancecustomer extension in the extension folder
13. Restore the AH settings.php with the copy saved in step 8
14. Don't forget to clear cache
That's it.
NOTE if using NodeJS: If you are going to provide in automated hosting Co-Browsing support using NodeJS. I suggest edit
These two templates and set static nodejs address. I suggest to have https in general, will avoid problems with sites which hash https enabled.
https://github.com/LiveHelperChat/autom … lhcobrowse
******************
Offline
Hi,
Looks +- correct, just how I usually do it:
1. Like I have my enviroment like this "/var/www/client/lhc_web" I just do
git pull origin master
2. To update existing instances databases and clear cache. I run update instance script from manager root folder and clear cache from customers
cd /var/www/manager/lhc_web && php cron.php -s site_admin -e instance -c cron/update_instances
cd /var/www/client/lhc_web && php cron.php -s site_admin -c cron/util/clear_cache
3. Now i just go and update default instances database doc_3.sql, to see what was changed I go to github automated hosting repository to see what's good there.
4. If you are using NodeJS Helper extension there was some changes there.
Basically, that's all.
Offline
After going through the update and reading your reply, I realized there is a simpler method of updating a site with Automated Hosting (AH) when not using a git repository.
The approach below does not affect the configuration files.
I have a question about your step 3 where you "update default instances doc_3.sql. Would you provide details of what to check and if that step needs to be added to the ones below?
**********************tested (on one installation) and seemed to work fine ************
The following assumes the main install of LHC is in lhc_web and the AH customer copy is in lhc_customer.
For example purposes the folders are the following (change as needed):
/var/www/chatserver/lhc_web
/var/www/chatserver/lhc_customer
1. Update Live Helper Chat using the standard instructions https://livehelperchat.com/article/view/63
2. Also overwrite the same folders in lhc_customer as in the main lhc_web folder: doc, ezcomponents, lib, modules, pos, translations, and design folders.
3. Download the Automated Hosting files, extract the new version of instance overwrite the instance folder in the main installaion lhc_web/extension/instance
4. Extract the new version of instancecustomer overwrite the instancecustomer folder in the customer installaion lhc_customer/extension/instancecustomer
5. If you have made any customizations to the automated hosting, reapply them.
5. Update the exsting customer databases using the following:
cd /var/www/chatserver/lhc_web && php cron.php -s site_admin -e instance -c cron/update_instances
6. Clear the cache of the customer installation:
cd /var/www/chatserver/lhc_customer && php cron.php -s site_admin -c cron/util/clear_cache
NOTE if using NodeJS: If you are going to provide in automated hosting Co-Browsing support using NodeJS. I suggest edit these two templates and set static nodejs address. I suggest to have https in general, will avoid problems with sites which hash https enabled.
https://github.com/LiveHelperChat/autom … lhcobrowse
************************
Here is a bash script (simple copy commands) used to update the LHC folders. Assumes the same folder structure as above and the most recent version of LHC is extracted into the chatserver folder. Adjust paths as needed. Give the script execution privileges and run it from the command link. I named it "updateLHC.sh"
#!/bin/bash
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/doc /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/ezcomponents /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/lib /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/modules /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/pos /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/translations /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/design /var/www/chatserver/lhc_web/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/doc /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/ezcomponents /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/lib /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/modules /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/pos /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/translations /var/www/chatserver/lhc_customer/
cp -R /var/www/chatserver/livehelperchat-master/lhc_web/design /var/www/chatserver/lhc_customer/
Last edited by devman (2015-02-12 19:44:57)
Offline
Hi,
As for third usually i just go to https://github.com/LiveHelperChat/autom … c/db_3.sql and click history,
then i see what was changed and just see do I have these changes or not and then add them. It's a little bit pain in the a** until i find a time, to migrate to JSON DB format as LHC itself updates database form itself. This would allow override default DB structure from another customer extension which would override default database. etc.
So seems all
Offline
Sorry, I am still a little unclear.
Is the step of checking db_3.sql a step that you take because you're the developer or does every installation with AH need to check that too?
It looks like the newest db_3.sql is copied over during the update so new databases will be based on that sql file.
And the manually run cron.php updates all the existing customer databases.
I am not sure where you are adding the differences (if any are found).
Thanks!
Offline
Hi,
Yes if you just do replace everything gonna be just fine. Like I personally have tweaked few default mail templates, subject etc. I have to update manually this file
Offline
Hi,
I had an issue with upgrading to 2.27 from 2.22 (posted here to keep upgrading automated hosting in one place).
When I tried to update the existing databases with cron (step 5 above) it threw an error:
Uncaught exception 'ezcPersistentQueryException' with message 'A query failed internally in Persistent Object: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'lhc_instance_client.client_title' in 'field list'
I realized the lhc_instance_client table had not been updated. I must have missed a step somewhere but I could not find where the table was supposed to get updated.
To resolve, I had to create a sql query from the install.sql file and update the database.
What did I miss? Where is the database updated when upgrading automated hosting?
Here is the query:
ALTER TABLE `lhc_instance_client`
ADD `files_supported` int(11) NOT NULL DEFAULT '1',
ADD `atranslations_supported` int(11) NOT NULL DEFAULT '1',
ADD `cobrowse_supported` int(11) NOT NULL DEFAULT '1',
ADD `forms_supported` int(11) NOT NULL DEFAULT '1',
ADD `cannedmsg_supported` int(11) NOT NULL DEFAULT '1',
ADD `faq_supported` int(11) NOT NULL DEFAULT '1',
ADD `feature_1_supported` int(11) NOT NULL,
ADD `feature_2_supported` int(11) NOT NULL,
ADD `feature_3_supported` int(11) NOT NULL,
ADD `reporting_supported` int(11) NOT NULL DEFAULT '1',
ADD `chatbox_supported` int(11) NOT NULL DEFAULT '1',
ADD `browseoffers_supported` int(11) NOT NULL DEFAULT '1',
ADD `questionnaire_supported` int(11) NOT NULL DEFAULT '1',
ADD `proactive_supported` int(11) NOT NULL DEFAULT '1',
ADD `screenshot_supported` int(11) NOT NULL DEFAULT '1',
ADD `blocked_supported` int(11) NOT NULL DEFAULT '1',
ADD `footprint_supported` int(11) NOT NULL DEFAULT '1',
ADD `previouschats_supported` int(11) NOT NULL DEFAULT '1',
ADD `chatremarks_supported` int(11) NOT NULL DEFAULT '1',
ADD `autoresponder_supported` int(11) NOT NULL DEFAULT '1',
ADD `geoadjustment_supported` int(11) NOT NULL DEFAULT '1',
ADD `onlinevisitortrck_supported` int(11) NOT NULL DEFAULT '1',
ADD `client_title` varchar(250) NOT NULL,
ADD `phone_number` varchar(250) NOT NULL DEFAULT '',
ADD `sms_left` int(11) NOT NULL DEFAULT '0',
ADD `sms_plan` int(11) NOT NULL DEFAULT '0',
ADD `soft_limit_type` int(11) NOT NULL DEFAULT '0',
ADD `soft_limit` int(11) NOT NULL DEFAULT '0',
ADD `hard_limit_type` int(11) NOT NULL DEFAULT '0',
ADD `hard_limit` int(11) NOT NULL DEFAULT '0',
ADD `sms_processed` int(11) NOT NULL DEFAULT '0',
ADD `sms_supported` int(11) NOT NULL DEFAULT '0',
ADD `hard_warning_send` int(11) NOT NULL DEFAULT '0',
ADD `soft_warning_send` int(11) NOT NULL DEFAULT '0',
ADD `phone_default_department` int(11) NOT NULL,
ADD `chat_supported` int(11) NOT NULL DEFAULT '1',
ADD `custom_fields_1` text NOT NULL,
ADD `custom_fields_2` text NOT NULL,
ADD `custom_fields_3` text NOT NULL,
COMMENT='';
Offline
It does not exists, in some time it will migrate to json format I have for LHC but at the moment the only way just do what you did Just not enough time...
Offline
Updating from 2.27 to 2.30 found these other fields in the install.sql that needed to be updated in SQL. Here is a script to add them.
ALTER TABLE `lhc_instance_client`
ADD `cobrowse_forms_supported` int(11) NOT NULL DEFAULT '1',
ADD `speech_supported` int(11) NOT NULL DEFAULT '1',
ADD `transfer_supported` int(11) NOT NULL DEFAULT '1',
ADD `operatorschat_supported` int(11) NOT NULL DEFAULT '1',
ADD `xmpp_supported` int(11) NOT NULL DEFAULT '1',
ADD `offline_supported` int(11) NOT NULL DEFAULT '1',
ADD `phone_number_data` text NOT NULL DEFAULT '',
ADD `phone_response_data` text NOT NULL DEFAULT '',
ADD `phone_response_timeout_data` text NOT NULL DEFAULT '',
COMMENT='';
Also for those of you updating from previous versions, read the install doc.txt again. The new parameters for the settings.ini caught me by throwing errors.
'support_mail' => '***.com',
'sender_mail' => '***.com',
'phoneattributes' => array(
),
Offline
Pages: 1