MODULECRAFTER ENTERPRISE LIVECHAT v2.0.0 - CPANEL/WHM INSTALL
============================================================

TARGET APPLICATION ROOT
/home/YOUR_CPANEL_USER/chat.modulecrafter.com

This folder can remain OUTSIDE public_html.

1. Extract the ZIP directly into the application root above.

2. In cPanel create a MySQL/MariaDB database + database user and grant
   that user ALL PRIVILEGES on the database.

3. Create the environment file:

   cd ~/chat.modulecrafter.com
   cp .env.example .env

4. Generate secrets:

   openssl rand -hex 48    # JWT_SECRET
   openssl rand -hex 48    # VISITOR_JWT_SECRET
   openssl rand -hex 32    # INTEGRATION_ENCRYPTION_KEY

5. Edit .env with:
   APP_URL=https://chat.modulecrafter.com
   exact cPanel DB name/user/password
   the generated secrets

6. Activate Node 20 and install:

   source ~/nodevenv/chat.modulecrafter.com/20/bin/activate
   cd ~/chat.modulecrafter.com
   npm install
   npm run build
   npm run migrate
   npm run create-admin
   npm run bootstrap
   npm run doctor

7. cPanel > Setup Node.js App:

   Node: 20.x+
   Mode: Production
   Root: chat.modulecrafter.com
   URL: https://chat.modulecrafter.com
   Startup: server.js

8. Restart the application.

9. Open:
   https://chat.modulecrafter.com/health
   https://chat.modulecrafter.com/admin

10. Paste the embed code printed by `npm run bootstrap` into your website.

For strong continuous WebSocket ringing on a WHM server, use PM2 + the
Apache reverse proxy example in deploy/apache-whm-proxy.conf.example.

Read README.md for SMTP, Meta, AI, FCM, TURN/WebRTC and WHMCS setup.
