User Tools

Site Tools


terminal:caddy

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
terminal:caddy [2024/08/18 01:55] – created meloterminal:caddy [2024/09/06 18:08] (current) melo
Line 1: Line 1:
 ===== caddy notes ===== ===== caddy notes =====
 +    
 +static site:
 +<code>https://example.com {
 +        root * "/path/to/dir"
 +        file_server
 +}</code>
 +
 +file browse
 +<code>https://example.com {
 +    root * "/path/to/dir"
 +    file_server browse
 +}</code>
  
 file browse: grid default/forced view file browse: grid default/forced view
-<code>root * "/path/to/dir" +<code>https://example.com { 
-file_server browse+    root * "/path/to/dir" 
 +    file_server browse 
 + 
 +    @directories `path('*/') && {query} == ''
 +        redir @directories ?layout=grid 
 +}</code> 
 +     
 +reverse proxy: 
 +<code>https://example.com { 
 +        reverse_proxy 192.168.1.123:8080 
 +}</code> 
 + 
 +reverse proxy with basic auth: 
 +<code>https://example.com { 
 +        reverse_proxy 192.168.1.123:8080 
 +        basicauth /* { 
 +                username basicauth_hash 
 +        }
  
-@directories `path('*/') && {query== ''` +}</code> 
-    redir @directories ?layout=grid</code>+<code>htpasswd -nbBC 10 username password_to_be_hashed</code>
terminal/caddy.1723946104.txt.gz · Last modified: 2024/08/18 01:55 by melo

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki