All checks were successful
Deploy to Production / Build and Deploy (push) Successful in 5s
1.7 KiB
1.7 KiB
Deployment Still Failing — 502 Error
Date: 2026-05-12 (second attempt)
Problem
After push of dc4244f, deploy relaunched BUT:
- postgres container was NOT recreated with new pgvector/pgvector:pg16 image
- Still running postgres:16-alpine — no pgvector — type "vector" does not exist
- docker compose pull postgres added in deploy.yaml is not enough — need docker compose up -d --force-recreate postgres
Production logs (192.168.1.190)
- memento-web: Restarting loop
- memento-postgres: healthy but STILL on postgres:16-alpine
- Error: type "vector" does not exist
Root cause
deploy.yaml does docker compose build then docker compose up -d BUT:
- postgres has no build: directive — uses image directly
- docker compose up -d does NOT recreate container if image didnt change locally
- Even with docker compose pull, existing container may not be recreated
What must be fixed
1. deploy.yaml (.gitea/workflows/deploy.yaml)
Add BEFORE docker compose up -d:
- docker compose pull postgres
- docker compose up -d --force-recreate postgres
- Wait for postgres healthy before continuing Or use: docker compose up -d --force-recreate --build
2. Verify docker-compose.yml has correct image
image: pgvector/pgvector:pg16
3. Prisma migration is stuck
Old migration 20260512120000_pgvector_and_fts_search marked as failed in _prisma_migrations. Need to mark it resolved after pgvector is installed.
4. Correct deployment order
- Pull + recreate postgres with pgvector
- Wait postgres healthy
- Create vector extension: CREATE EXTENSION IF NOT EXISTS vector
- Resolve failed migration in _prisma_migrations
- Start memento-web (will run migration)
- Start mcp-server