Chatwoot Support Platform Deployment
Date: 2026-04-07 Status: Production Ready (Ops Complete)
VM Infrastructure
| Item | Value |
|---|---|
| Provider | GCP |
| Instance | chatwoot-vm |
| Zone | us-central1-a |
| Machine Type | e2-standard-2 |
| External IP | 34.30.168.118 |
DNS
| Hostname | Points To |
|---|---|
| support.aovis.app | 34.30.168.118 |
SSL
- Let's Encrypt (Certbot)
- Certificate:
/etc/letsencrypt/live/support.aovis.app/
Container Stack
| Service | Image | Port |
|---|---|---|
| postgres | pgvector/pgvector:pg16-trixie | 5432 |
| redis | redis:alpine | 6379 |
| rails | chatwoot/chatwoot:latest | 3000 |
| sidekiq | chatwoot/chatwoot:latest | - |
Configuration
- Compose:
~/chatwoot/docker-compose.yaml - Env:
~/chatwoot/.env(VM-local, never commit)
Database (生产环境 - 已加固)
- User: postgres
- Password: 已升级为 48 位随机密码
- Host: postgres (Docker internal)
SMTP (生产环境 - 已配置)
- Host: smtp.qiye.163.com
- Port: 465 (SSL) 或 994 (STARTTLS)
- User: [email protected]
Secrets (VM-local only)
SECRET_KEY_BASE: 64 位十六进制密钥- 数据库密码: 48 位随机字符串
- SMTP 密码: 网易企业邮授权码
- 以上均存储在 VM 本地
~/chatwoot/.env,禁止提交到仓库
Verification (2026-04-06)
- support.aovis.app → 200 OK
- Chatwoot 后台可登录
- 用户已创建 ([email protected], SuperAdmin)
- SECRET_KEY_BASE 已持久化到 .env
- 数据库密码已升级
- SMTP 配置已生效
Commands
# SSH
gcloud compute ssh chatwoot-vm --zone=us-central1-a
# Restart
cd ~/chatwoot && docker compose restart
# Logs
cd ~/chatwoot && docker compose logs -f
Risks
- 首次部署后需手动
sudo systemctl reload nginx - 数据库密码存储在 VM 本地,备份时请包含 .env 文件
Operations Completed (2026-04-07)
Deployment Record
- Phase 0 deployment record: docs/chatwoot-phase-0-deployment-record.md
- Notification/email behavior notes: docs/chatwoot-phase-0-deployment-record.md
- Canonical field mapping and live verification notes: docs/chatwoot-context-integration.md
Inbox Configuration
- Inbox Name: AOVIS
- Channel: Web Widget (Channel::WebWidget)
- Reply Time Setting: in_a_few_minutes
- Email Continuity: Enabled (continuity_via_email: true)
- Email Collection: Enabled
Widget Customization
- Welcome Title: "Welcome to AOVIS Support"
- Welcome Tagline: "We are here to help. Send us a message and we will respond as soon as possible."
- Website URL: aovis.us
- Allowed Domains: (none - accepts all)
Support Entry Convention
- Primary storefront support actions now open Chatwoot first.
- Preferred labels:
Chat with UsandGet Support. - If a support button points to a page instead of chat, use
Support Center. - Keep
[email protected]as a secondary fallback or small-text contact option. - Do not promote email above Chatwoot when the widget is available.
Health Check Commands
# All services
docker ps
# Rails API
curl -s -o /dev/null -w '%{http_code}' http://localhost:3000/
# Nginx
sudo systemctl status nginx
# PostgreSQL (inside container)
docker exec chatwoot-postgres-1 psql -U postgres -d chatwoot_production -c 'SELECT 1'
# Redis
docker exec chatwoot-redis-1 redis-cli ping
Maintenance Commands
# Restart all services
cd ~/chatwoot && docker compose restart
# Restart specific service
docker compose restart rails
# View logs
docker compose logs -f rails
docker compose logs -f sidekiq
# SSH to container
docker exec -it chatwoot-rails-1 bash
Shared Infrastructure Context
This section preserves the lightweight operational context that used to live in the stray ai_System/memory/infrastructure_context.md file. It is kept here so future operators and AI tools have one canonical deployment reference.
Current Deployment State
- Chatwoot support stack is live on GCP
chatwoot-vminus-central1-a. - Static IP:
34.30.168.118. - Support domain:
support.aovis.app. - Direct store production deploy path uses
aovis-store-staging-vmin projectaovis-site-1. - For the current Chatwoot widget integration history, see the Phase 0 deployment record and the live release notes:
Operational Notes
- Use
gcloud compute sshfor VM access. - The working Google account for
aovis-site-1access is the account that hasaovis-site-1visibility ingcloud projects list. - VM-local secrets must stay in
/opt/aovis/aovis-store-staging/.env.productionfor the app VM and~/chatwoot/.envfor the Chatwoot VM. - Do not overwrite VM-local secret files with repo sync, bulk
scp, orrsync. - Keep production secrets out of repository files, docs, and shared memory.
Chatwoot Widget
aovis.apploads Chatwoot fromhttps://support.aovis.app.- Widget token and host are VM-local environment variables on the app VM.
- The widget integration remains a minimal footer-level injection through the shared layout.
Verification Summary
support.aovis.appreturned200 OK.aovis.appreturned200 OKfrom the VM-side check.pm2foraovis-store-stagingwas online after the release build and restart.- Production build completed successfully on the app VM after the Chatwoot widget integration.
Reminder
- This file should only contain deployment summary and handling rules.
- Never add raw passwords, tokens, or full secret values here.
Backup & Recovery
- Secrets Location:
~/chatwoot/.env(VM-local only) - Database: PostgreSQL in Docker, data persists in volume
- SECRET_KEY_BASE: Stored in
.env, required for Rails boot - Backup Note: Include
~/chatwoot/.envin any VM-level backups