update 2025-04-06
Changes: - fix README.md old json format usage - rename "redirect" option to "proxy_pass" - move docker-compose.yml and nginx.conf.j2 to examples and add to .gitignore - fix situation when one domain from domains.txt and servers.yaml appeared twice in nginx.conf
This commit is contained in:
24
README.md
24
README.md
@@ -2,19 +2,17 @@
|
||||
|
||||
## Preparation
|
||||
|
||||
Add your domains for _certbot_ to [domains.txt file at nginx directory](nginx/domains.txt) and servers configuration
|
||||
json file in format
|
||||
```json
|
||||
{
|
||||
"domain": {
|
||||
"redirect": "redirection_path",
|
||||
"options": [
|
||||
"some_nginx_option_on_server_level here;"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
to [servers.json file at nginx directory](nginx/servers.json).
|
||||
1. Copy and edit (if needed) [nginx/nginx.conf.j2](nginx/nginx.conf.j2.example) file.
|
||||
2. Add your certified domains to nginx/domains.txt file ([example](nginx/domains.txt.example)).
|
||||
|
||||
These domains will be used by _certbot_ to monitor and update (if possible) certificates. _Nginx_ will also setup
|
||||
http server for the given entries.
|
||||
|
||||
However if the domain is set both in domains.txt and servers.yaml (next step), _nginx_ will
|
||||
use https with certificates at the given path. That will fail nginx startup if the certificate
|
||||
to at least one domain is missing (--http-only option will skip domains.txt check).
|
||||
|
||||
3. Add your servers section configuration to nginx/servers.yaml ([example](nginx/servers.yaml.example)).
|
||||
|
||||
User email used for certbot can be set as environment variable at build process or in .env file.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user