Skip to main content
Skip table of contents

CX Upgrade Guide CX-4.3 to CX-4.4

  1. Remove any active state of the system.

    CODE
    # Open the redis shell
    kubectl exec -n ef-external -it redis-master-0 -- redis-cli -a Expertflow123
     
    # Inside the redis shell
    flushall
     
    # ctrl + c (to get out of the shell)

  2. Remove the current solution deployment

    CODE
    # Navigate to the following folder of the existing release i.e. CX-4.3
    cd cim-solution/kubernetes
    
    kubectl delete -f cim/StatefulSet/ef-amq-statefulset.yaml
    kubectl delete -f cim/ConfigMaps/
    kubectl delete -f cim/Deployments/
    kubectl delete -f cim/Services/
     
    #if you are using nginx (RKE)
    kubectl delete -f cim/Ingresses/nginx
     
    #if you are using traefik
    kubectl delete -f cim/Ingresses/traefik
    
    # Remove Rasa-X
    helm uninstall rasa-x -n rasa-x

  3. Make backup of the current cim-solution folder.

    CODE
    # Navigate to the parent directory where the cim-solution folder is placed and run:
    mv cim-solution cim-solution-old

  4. Clone the CX-4.4 release from gitlab and place it on target server.

    CODE
    git clone -b CX-4.4 https://efcx:RecRpsuH34yqp56YRFUb@gitlab.expertflow.com/cim/cim-solution.git

  5. Navigate to the cim-solution/kubernetes directory in the newly cloned release.

    CODE
    cd cim-solution/kubernetes

  6. Update the FQDN. 

    CODE
    # Change the <FQDN> in the below given commands to your actual FQDN.
    sed -i 's/devops[0-9]*.ef.com/<FQDN>/g' cim/ConfigMaps/* pre-deployment/grafana/*  pre-deployment/keycloak/* cim/Ingresses/traefik/* cim/Ingresses/nginx/*
    
    sed -i -e 's@value: http://devops.ef.com/bot-framework@value: https://<CIM-FQDN>/bot-framework@' external/rasa-x/values-small.yaml
    
    sed -i -e 's@value: https://devops.ef.com@value: https://<CIM-FQDN>@' external/rasa-x/values-small.yaml

  7. Replace the reporting connector config files from cim-solution-old to cim-solution

    Copy the reporting-connector.conf file from cim-solution-old/kubernetes/pre-deployment/reportingConnector directory and replace with the files in cim-solution/kubernetes/pre-deployment/reportingConnector directory.

    CODE
    # Move to the root/parent directory before executing below mentioned commands
    
    cp cim-solution-old/kubernetes/pre-deployment/reportingConnector/reporting-connector.conf cim-solution/kubernetes/pre-deployment/reportingConnector
    
    # Now move back to the previous directory cim-solution/kubernetes

  8. (Optional) Configure reporting components connection with MySQL over SSL

    The 4.4 release support the reporting components connection with MySQL on SSL. To configure the reporting connector with MySQL over SSL, consult this guide. To configure Superset with MySQL over SSL, refer to the Superset SSL Configuration section of this guide.

    CODE
    kubectl -n expertflow delete configmap ef-reporting-connector-conf
     
    kubectl -n expertflow create configmap ef-reporting-connector-conf --from-file=pre-deployment/reportingConnector/reporting-connector.conf

  9. You can specify the schedule for your cron job by setting the parameter schedule: "*/5 * * * *" in cim-solution/kubernetes/pre-deployment/reportingConnector/ef-reporting-connector-cron.yaml file where the value '5' is a default time which corresponds to the interval in minutes. Replace the value by replacing '5' with your specified minutes.

  10. Apply the configuration defined in pre-deployment/reportingConnector/ef-reporting-connector-cron.yaml file by the below command to run cron job for reporting-connector.

    CODE
    kubectl apply -f pre-deployment/reportingConnector/ef-reporting-connector-cron.yaml -n expertflow

  11. Run the MySQL database update script present in cim-solution/kubernetes/pre-deployment/reportingConnector/SQLScripts/dbupdate directory to get the latest database schema.

  12. Before proceeding, copy the post-deployment/config/grafana/supervisor-dashboards/datasource.yml from the old backup (cim-solution-old)  to the new cim-solution. Commands are shown below.

    CODE
    # Navigate to the root directory of cim-solution and cim-solution-old
    cd ../../
     
    # Copy the datasource.yml file from cim-solution-old to cim-solution
    cp cim-solution-old/kubernetes/post-deployment/config/grafana/supervisor-dashboards/datasource.yml cim-solution/kubernetes/post-deployment/config/grafana/supervisor-dashboards/datasource.yml
     
    # After it is done, Navigate back to the following directory before continuing
    cd cim-solution/kubernetes

  13. Update the Grafana deployment.

    Run only the commands as per your reporting database type. (MSSQL/MYSQL)

    1. FOR MYSQL ONLY

      CODE
      # Delete Grafana MYSQL Dashboard Config Map.
      kubectl -n ef-external delete configmap ef-grafana-supervisor-dashboard-mysql

      CODE
      # Create Grafana MYSQL Dashboard Config Map.
      kubectl create configmap ef-grafana-supervisor-dashboard-mysql -n ef-external --from-file=post-deployment/config/grafana/supervisor-dashboards/Supervisor_Dashboard_CIM-mysql.json
       
      sed -i -e 's@configMapName: <configmap-map-name>@configMapName: ef-grafana-supervisor-dashboard-mysql@' external/bitnami/grafana/values.yaml

      CODE
      sed -i -e 's@fileName: <file-name>@fileName: Supervisor_Dashboard_CIM-mysql.json@' external/bitnami/grafana/values.yaml

    2. FOR MSSQL ONLY.

      CODE
      # Delete Grafana MSSQL Dashboard Config Map.
      kubectl -n ef-external delete configmap ef-grafana-supervisor-dashboard-mssql
      
      # Create Grafana MSSQL Dashboard Config Map.
      kubectl create configmap ef-grafana-supervisor-dashboard-mssql -n ef-external --from-file=post-deployment/config/grafana/supervisor-dashboards/Supervisor_Dashboard_CIM-mssql.json
       
      sed -i -e 's@configMapName: <configmap-map-name>@configMapName: ef-grafana-supervisor-dashboard-mssql@' external/bitnami/grafana/values.yaml
      
      sed -i -e 's@fileName: <file-name>@fileName: Supervisor_Dashboard_CIM-mssql.json@' external/bitnami/grafana/values.yaml

  14. Update Grafana Helm

    CODE
    helm uninstall grafana -n ef-external

    CODE
    helm upgrade --install=true --wait=true --timeout=10m0s  --debug  --namespace=ef-external --values=external/bitnami/grafana/values.yaml grafana  external/bitnami/grafana

  15. Create a database named “scheduler” for scheduled activities.

    CODE
    # Login to Postgres client
    # On your terminal, execute the below command.
    helm -n ef-external status ef-postgresql
    
    # It will return some steps to connect to postgresql client.
    
    # Execute the command returned after text "To get the password for "postgres" run:". It should be starting with keyword "export".
    
    # After this, execute the next command returned after text "To get the password for "sa" run:". It should be starting with keyword "export".
    
    # After this, execute the next command returned after text "To connect to your database run the following command:". It would be in 3 lines so copy all of it and paste it to execute it. 
    
    # After this, you should see terminal with pre word as "licenseManager=>". If not then you can try pressing enter to see this.
    
    # Here, you can execute this command "CREATE DATABASE scheduler;" (without quotes)
    
    # After executing this command, you can verify the DATABASE creation using the command "\l+" (without quotes). It will list all databases. 
    
    # At the end you can execute "\q" to quit from the client.

  16. Update the solution deployment

    CODE
    # Install Rasa-X
    helm  upgrade --install=true --wait=true --timeout=10m0s --debug   rasa-x    --namespace rasa-x     --values external/rasa-x/values-small.yaml  external/rasa-x
    
    # Apply Cim Solution Components
    kubectl apply -f cim/ConfigMaps/
    kubectl apply -f cim/StatefulSet/ef-amq-statefulset.yaml
    kubectl apply -f cim/Services/
    kubectl apply -f cim/Deployments/
     
    #if you are using nginx
    kubectl apply -f cim/Ingresses/nginx
     
    #if you are using traefik
    kubectl apply -f cim/Ingresses/traefik
  17. After Rasa-x Installation we need to configure Rasa again using this rasa configuration guide.

  18. The customer widget url is now changed in 4.4(Current) release. Please use below mentioned URLs now onwards.

For 4.4 Release, Please do not use TRAEFIK as ingress.

Chat Initiation URL

  1. Create a pre-chat form in unified admin. Refer to this guide.

  2. The web-init-widget is now capable of calling the deployment of CIM from within the URL

    CODE
    https://{FQDN}/customer-widget/#/widget?widgetIdentifier=<widget-identifier>&serviceIdentifier=<service-identifier>&channelCustomerIdentifier=<customer-channel-identifier>
  3. For the chat history, use the following URL

    CODE
    https://{FQDN}/customer-widget/widget-assets/chat-transcript/

{FQDN} →  FQDN of Kubernetes Deployment 

If every thing worked fine until this point, you may remove the cim-solution-old directory

CODE
# Move to the parent directory
rm -rf cim-solution-old

Connector Configuration Guide:

  1. Viber Connector Configuration

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.