wowo-zZ
d631b0e20a
fix(ops): resolve storage permission and audit log JSONB type issues
...
Fixes two critical issues when deploying with runtime.sh:
1. Storage Permission Error
- Problem: AccessDeniedException when publishing skills
- Root cause: /var/lib/skillhub/storage owned by root, but app runs as 'app' user
- Solution: Pre-create storage directory with correct permissions in Dockerfile
2. Audit Log JSONB Type Error
- Problem: PostgreSQL JSONB type mismatch when recording audit logs
- Root cause: Missing type mapping annotation in AuditLog entity
- Solution: Add @JdbcTypeCode(SqlTypes.JSON) annotation and V7 migration
Changes:
- server/Dockerfile: Add storage directory creation and permission setup
- server/skillhub-domain/.../AuditLog.java: Add @JdbcTypeCode annotation
- server/skillhub-app/.../V7__fix_audit_log_jsonb_type.sql: Migration for existing data
Impact:
- New deployments: Issues resolved automatically
- Existing deployments: Flyway auto-applies V7 migration on upgrade
2026-03-14 11:23:19 +08:00
vsxd
dbb6d9f39e
feat(ops): improve Dockerfile caching, add dockerignore, docker profile, Makefile help
...
- Server Dockerfile: add Maven dependency caching layer for faster rebuilds
- Add .dockerignore for server and web to reduce build context
- Add docker profile to application.yml for container env var mapping
- Makefile: add help, logs, db-reset targets with ## annotations
2026-03-12 17:50:34 +08:00