Gitea 是一个用 Go 语言写的代码托管软件。
配置
- 禁止注册: 在
[service]section 中添加DISABLE_REGISTRATION = true - 本地监听: 在
[server]section 中添加HTTP_ADDR = 127.0.0.1 - 更改默认主题为暗色主题: 在
[ui]section 中添加DEFAULT_THEME = arc-green1 - 延长 remember me 的时间: 在
[security]section 中添加LOGIN_REMEMBER_DAYS = 1002 - robots.txt: 将 robots.txt 的内容写入
/var/lib/gitea/custom/robots.txt3
在 Ubuntu Server 中安装 4
添加 key
curl -sL -o /etc/apt/trusted.gpg.d/morph027-gitea.asc https://packaging.gitlab.io/gitea/gpg.key添加 repo
echo "deb [arch=amd64] https://packaging.gitlab.io/gitea gitea main" | sudo tee /etc/apt/sources.list.d/morph027-gitea.list安装
sudo apt update
sudo apt install gitea