Skip to content

Deployment and operations

Use a stable release, Node.js 22+, and MySQL for production. Pin the target version and keep its configuration and upgrade records for future maintenance.

终端窗口
cp .env.example .env
# Set BAILING_ENV=production, a random BAILING_TOKEN, MySQL, and model configuration
npm ci
npm run db:init
npm run admin:create -- admin
npm start

The public installer deploys the current stable distribution:

终端窗口
curl -fsSL https://www.bailinghub.com/install.sh | sh
Area Requirement
Environment Inject secrets from environment variables or a secret manager
Database Run every pending migration; never edit an applied migration
Administrator Bootstrap only an empty admin table; rotate initial credentials
Health Use /health; use /version to verify application and contract versions
Audit retention BAILING_AUDIT_RETENTION_DAYS=0 means no automatic deletion
Rate limits Use the MySQL-backed ledger for consistent multi-instance semantics
Callbacks Trace delivery failures and retain polling by job_id
Diagnostics Export one redacted job trace, not a full database or live secrets
  1. Read the target release notes and compatibility guide;
  2. back up the database and deployment configuration;
  3. run pending migrations and verify the migration ledger;
  4. verify /health, /version, console login, and a harmless task;
  5. resume traffic and observe queues, errors, and tool calls.

The v0.10.0 → v0.10.1 patch adds no SQL migrations; the existing public v0.9.4 → v0.10.0 path also added none. Earlier versions still apply every outstanding migration, including 068, to the actual state and configuration databases. Migrate a shared database once. npm run db:init handles state MySQL only; use the official migration entry for separate configuration MySQL. Startup does not migrate automatically. Follow the 0.10.1 upgrade guide for Core and business SDK pairing, retaining the earlier upgrade requirements.

See the fixed v0.10.1 Operations guide and Compatibility guide.