I have a 1-click install droplet with Gitea, but it only works over HTTP how can I set it up to work over HTTPS?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Sign up for Infrastructure as a Newsletter.
Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
I have figured out how to set it up (but I think it only works with domain names though…) And don’t use the 1-click droplet, instead create a standard ubuntu 18.04 droplet :
Initial updates & installs
Set up users
Folder structure setup
Nginx
Gitea installation
ssl (Only for domain names)
Paste in this code and replace [YOUR-DOMAIN-HERE] with ex. example.com (your domain name)
*server {
listen 443 ssl; server_name [YOUR-DOMAIN-HERE]; ssl_certificate /etc/letsencrypt/live/[YOUR-DOMAIN-HERE]/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/[YOUR-DOMAIN-HERE]/privkey.pem;
}
Redirect HTTP requests to HTTPS
server {
listen 80; server_name [YOUR-DOMAIN-HERE]; return 301 https://$host$request_uri; } *
start gitea
I have the same issue and the link above does not work. I tried everything from the official Gitea Docs but it simply does not work. Can anyone please provide some more details?
Hello,
There are a few ways to achive that, you could take a look at the Gitea official documentation on how to do this here:
https://docs.gitea.io/en-us/https-setup/
Let me know if something is not clear and I’ll be happy to help!
Regards, Bobby