sudo apt-get install certbot -t jessie-backports<\/pre>\nTo get the certificate file, you can use the following command :<\/p>\n
certbot certonly --webroot -w \/var\/www\/git -d mygitserver.tld<\/pre>\nRemember that Let’s Encrypt certificate is only valid during 90 days, so put this in your crontab to automatically generate new certificate before it\u00a0expires :<\/p>\n
0 1 1 * * certbot renew --quiet\n36 8 2 * * certbot renew --quiet<\/pre>\nYou will find the following settings in the “[server]” part of the Gitea “app.ini” file :<\/p>\n
[server]\nPROTOCOL = http\nDOMAIN = localhost\nROOT_URL = %(PROTOCOL)s:\/\/%(DOMAIN)s:%(HTTP_PORT)s\/\nHTTP_ADDR = 0.0.0.0\nHTTP_PORT = 3000<\/pre>\nChange them by :<\/p>\n
[server]\nPROTOCOL = http\nDOMAIN = mygitserver.tld\nROOT_URL = https:\/\/mygitserver.tld\nHTTP_ADDR = 0.0.0.0\nHTTP_PORT = 3000<\/pre>\nThen, to apply, restart the supervisor service :<\/p>\n
sudo service supervisor restart<\/pre>\n","protected":false},"excerpt":{"rendered":"Gitea is a self-hosted Git service forked from Gogs. It’s very easy to deploy and has a low system usage impact. It has features like : web interface wiki issues management admin dashboard In this howto, we will use SQLite Read More …<\/a><\/p>\n","protected":false},"author":1,"featured_media":106,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","footnotes":"","jetpack_publicize_message":"","jetpack_is_tweetstorm":false,"jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false}}},"categories":[9],"tags":[10,11],"jetpack_publicize_connections":[],"yoast_head":"\nInstalling Gitea on Debian - J\u00e9r\u00e9my Verda's IT Blog<\/title>\n \n \n \n \n \n \n \n \n \n \n \n \n\t \n\t \n\t \n \n \n \n \n \n\t \n\t \n\t \n