diff options
Diffstat (limited to 'docs/content/doc/usage/https-support.md')
-rw-r--r-- | docs/content/doc/usage/https-support.md | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/docs/content/doc/usage/https-support.md b/docs/content/doc/usage/https-support.md index 2e6bfdbcf..e2af38113 100644 --- a/docs/content/doc/usage/https-support.md +++ b/docs/content/doc/usage/https-support.md @@ -30,8 +30,22 @@ HTTP_PORT = 3000 CERT_FILE = cert.pem KEY_FILE = key.pem ``` + To learn more about the config values, please checkout the [Config Cheat Sheet](../config-cheat-sheet#server). +### Setting-up HTTP redirection + +The Gitea server is only able to listen to one port; to redirect HTTP requests to the HTTPS port, you will need to enable the HTTP redirection service: + +```ini +[server] +REDIRECT_OTHER_PORT = true +; Port the redirection service should listen on +PORT_TO_REDIRECT = 3080 +``` + +If you are using Docker, make sure that this port is configured in your `docker-compose.yml` file. + ## Using Let's Encrypt [Let's Encrypt](https://letsencrypt.org/) is a Certificate Authority that allows you to automatically request and renew SSL/TLS certificates. In addition to starting Gitea on your configured port, to request HTTPS certificates Gitea will also need to listed on port 80, and will set up an autoredirect to HTTPS for you. Let's Encrypt will need to be able to access Gitea via the Internet to verify your ownership of the domain. |