使用Gitea搭建Git服务器
安装
Ubuntu
1 2 3 4 5 6 7 8 |
pushd /opt/gitea mkdir -p custom/conf/ mkdir repos wget -O gitea https://dl.gitea.io/gitea/1.3.2/gitea-1.3.2-linux-amd64 chmod +x gitea nohup /opt/gitea/gitea web > /dev/null 2>&1 & |
配置
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
RUN_USER = root RUN_MODE = prod APP_NAME = Gmem Gitea [repository] ROOT = /opt/gitea/repos [server] PROTOCOL = https DOMAIN = git.gmem.cc HTTP_ADDR = 0.0.0.0 HTTP_PORT = 3443 ; 证书需要完整的链 CERT_FILE = /etc/letsencrypt/live/git.gmem.cc/fullchain.pem KEY_FILE = /etc/letsencrypt/live/git.gmem.cc/privkey.pem SSH_DOMAIN = git.gmem.cc ROOT_URL = https://git.gmem.cc/ DISABLE_SSH = false SSH_PORT = 22 LFS_START_SERVER = true LFS_CONTENT_PATH = /opt/gitea/data/lfs LFS_JWT_SECRET = s52JAPPWiOFpp8CZiPHrlGeHWtwv6WCphZtBG5vNLE8 OFFLINE_MODE = false [mailer] ENABLED = false [service] REGISTER_EMAIL_CONFIRM = false ENABLE_NOTIFY_MAIL = false DISABLE_REGISTRATION = true ENABLE_CAPTCHA = false REQUIRE_SIGNIN_VIEW = false DEFAULT_KEEP_EMAIL_PRIVATE = false DEFAULT_ALLOW_CREATE_ORGANIZATION = true DEFAULT_ENABLE_TIMETRACKING = true NO_REPLY_ADDRESS = noreply@gmem.cc [picture] DISABLE_GRAVATAR = false ENABLE_FEDERATED_AVATAR = false [openid] ENABLE_OPENID_SIGNIN = true ENABLE_OPENID_SIGNUP = false [session] PROVIDER = file [log] MODE = file LEVEL = Info ROOT_PATH = /opt/gitea/log |
Leave a Reply