multiple caddy files
This commit is contained in:
@@ -42,3 +42,13 @@ You can setup this rule for multiple domains by either writing them space sepera
|
||||
`{uri}` specified at the end of domain name preserves the path from the URL user entered.
|
||||
Now if anyone visits your website via server's IP address or using `www` subdomain they will be redirected to your root domain.
|
||||
**It just looks cleaner.**
|
||||
|
||||
## Multiple file caddy config
|
||||
|
||||
Caddy supports writing config in multiple files so that we don't polluting our main config. Just import all other caddy configs to the main caddy config.
|
||||
Usually we can structure our config files in any way it doesn't matter. But there are some common ways to structure it.
|
||||
|
||||
Place all other config files inside `/etc/caddy/conf.d/` directory and import Caddyfile from this directory to main config file.
|
||||
```Caddyfile
|
||||
import conf.d/*.Caddyfile
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user