Files
hexin-codex-bot 53b0c62120
Verify and deploy production / verify-and-deploy (push) Successful in 2m45s
ops: add PostgreSQL compose deployment
2026-10-05 16:01:01 +08:00
..

PostgreSQL deployment

The production database runs through Docker Compose and is only exposed on the server loopback interface. It is managed independently from the application CI deployment.

  • Database: rednote_studio
  • User: rednote_studio
  • Address from the host: 127.0.0.1:5432
  • Persistent data: /var/lib/rednote-tool-studio/postgres
  • Password secret: /etc/rednote-tool-studio/postgres-password

Start or update it on the production host:

docker compose -f /opt/rednote-tool-studio/postgres/compose.yml pull
docker compose -f /opt/rednote-tool-studio/postgres/compose.yml up -d
docker compose -f /opt/rednote-tool-studio/postgres/compose.yml ps

The password file must already exist, be owned by root, and use mode 0600. Never commit it to the repository.