Gitea: Self-Hosted Git Service
Deploy Gitea with Pigsty’s Compose template and connect it to external PostgreSQL.
Gitea is a lightweight open-source Git hosting platform.
Pigsty’s app/gitea template uses external PostgreSQL mode by default. Configure the database through GITEA_DB_* values in .env.
Quick Start
Default endpoints:
- Web:
http://git.pigstyorhttp://<IP>:8889 - SSH:
<IP>:222
Database Preparation
Connection string example:
Reverse Proxy and Upgrades
Gitea 28 serves notifications at /-/ws. Enable WebSocket support on the Nginx portal:
Before upgrading, back up PostgreSQL and /data/gitea together and record the running image digest. Restore matching database and file backups when rolling back. Gitea 28 defaults to removing completed Actions runs, logs, and artifacts after 400 days; check retention settings if those records need to be kept longer. See the Gitea 28 release notes.
Common Commands
References
- Gitea docs: https://docs.gitea.com/
- Pigsty template: https://github.com/pgsty/pigsty/tree/main/app/gitea
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)