Siti statici
Servi HTML, CSS, mmàggini e scarricamentu direttamenti dû discu. È a modalità Fluxheim cchiù sìmprici.
Quannu usarlo
Usa hosting staticu pi ducumentazzioni, pàggini pruduttu, scarricamentu e siti ca nun richiedunu codice applicativu a ogni request.
- ETag e request cunniziunali ridùcinu u trafficu ripitutu.
- I byte range funzionanu pi file cchiù granni.
- I dotfile hannu a ristari nigati ntê root pùbblici.
Esempio sito statico
[[vhosts]]
name = "docs"
hosts = ["docs.example.com"]
[vhosts.web]
root = "/srv/docs"
index_files = ["index.html"]
deny_dotfiles = true
Opzioni principali
| Opzione | Usalo quannu |
|---|---|
root | Vuoi na root filesystem bounded pi file pubblici. |
index_files | Na directory havi a risòrvirisi a un file index. |
deny_dotfiles | I file ammucciati nun hannu mai a diventari pùbblici pi erruri. |
directory_listing | Pubblichi intenzionalmente index stile repository. |
Esempio listing repository
[[vhosts.routes]]
name = "repo"
path_prefix = "/repo/"
[vhosts.routes.web]
root = "/srv/repository/public"
index_files = ["index.html"]
[vhosts.routes.web.directory_listing]
enabled = true
exact_size = false
Directory listings stay private-cache by default, skip symlink entries, and still prefer index files when they exist.