Production checklist

Security, reliability, performance and operations items to check before and after you put a Spica instance in front of real users.

Security

  • The default identity's password is changed (--passport-default-identity-password or application.defaultPassword), or the default identity is removed.
  • Every team member has a personal identity with only the policies they need.
  • Identities with full access use two-factor authentication.
  • The master key is long, random, stored in a secret manager and backed up.
  • The API is served over HTTPS only, and --public-url uses https://.
  • --cors-allowed-origins lists your apps' origins instead of *.
  • Response headers such as X-Frame-Options and Strict-Transport-Security are set with --response-header.
  • No API key with write access, or read access to private data, is used in browsers or mobile apps.
  • Every bucket that users can reach has read and write rules.
  • HTTP functions that change data use authenticate, and public ones use rateLimit.
  • Credentials used by functions are secrets, not environment variables.
  • Password policy, lockout and rate limits are configured for users.
  • Access tokens are short-lived and clients use refresh tokens.

Data

  • The database runs with authentication. MongoDB runs as a replica set, preferably with three members.
  • Automated backups of the database, files and function sources exist, and a restore has been tested.
  • Buckets have indexes for their common filters, sorts and rules.
  • Buckets that grow without bound (logs, notifications) have document limits.
  • Uploaded files and function sources live on durable, shared storage when you run several replicas.

Reliability and performance

  • Liveness and readiness probes use /status/live and /status/ready.
  • API containers have memory limits, and --function-builder-max-memory stays below them when you use the rollup builder.
  • Function timeouts match the real duration of their handlers.
  • Latency-sensitive functions use warm workers, and I/O-bound ones a higher concurrencyPerWorker.
  • Read-heavy public data is served with the bucket response cache or a CDN.
  • --replication is on when you run more than one API replica.
  • Your proxy allows WebSocket upgrades and long-lived connections on /api.
  • Your proxy's body size limit matches --storage-object-size-limit and --payload-size-limit.

Operations

  • Resources are kept in git and deployed with spica plan and spica apply from CI.
  • Access logs and function worker logs go to stdout and into your log platform.
  • Alerts exist for function errors, 5xx responses and database health.
  • You know how long logs and activity are kept (--common-log-lifespan) and it fits your audit needs.
  • Image versions are pinned, and upgrades are tested on staging first.
  • Unused identities, API keys and refresh tokens are reviewed and removed regularly.