feat: add editable application drafts tests and gitea deploy workflow

This commit is contained in:
cesnimda
2026-03-22 18:42:14 +01:00
parent 8041b43f47
commit 1fe3a68901
6 changed files with 239 additions and 3 deletions
+53
View File
@@ -0,0 +1,53 @@
# Production deployment notes
## Gitea Actions
This repo includes `.gitea/workflows/ci-deploy.yml` for:
- backend build
- backend tests
- frontend tests
- deployment to Ubuntu after successful tests on `main`
### Required secrets in Gitea
- `PROD_HOST`
- `PROD_USER`
- `PROD_SSH_KEY`
## Ubuntu server setup
Recommended app path:
- `/opt/job-tracker/app`
Requirements:
- Docker Engine
- Docker Compose plugin
- reverse proxy in front (Nginx, Caddy, or Traefik)
- `.env` file present on server in `/opt/job-tracker/app/.env`
## Database recommendation
For production, yes — use a real database.
### Recommended direction
Short term:
- SQLite is acceptable for a single-user or very small deployment
- keep backups and volume persistence
Better production choice:
- MariaDB or PostgreSQL
### My recommendation
- **PostgreSQL** if you want the best long-term maintainability and fewer edge cases
- **MariaDB** is also fine if that is what you already know or host elsewhere
If you stay on SQLite:
- okay for small personal use
- not ideal for concurrent writes, larger scale, or operational robustness
## Practical recommendation for this project
If this app is going to be a real production service on Ubuntu:
- move to PostgreSQL first if possible
- MariaDB is still a reasonable option if preferred
## Deployment flow
1. push to `main`
2. Gitea Actions runs tests
3. if green, workflow uploads repo to server
4. `deploy/deploy.sh` runs `docker compose build && docker compose up -d`