2022-09-16 08:26:26 -07:00
|
|
|
:80 {
|
2022-11-18 09:00:18 -08:00
|
|
|
redir /.well-known/webfinger /index.php/.well-known/webfinger 301
|
2022-09-16 08:26:26 -07:00
|
|
|
redir /.well-known/carddav /remote.php/dav 301
|
|
|
|
redir /.well-known/caldav /remote.php/dav 301
|
|
|
|
|
|
|
|
header {
|
|
|
|
# enable HSTS
|
|
|
|
Strict-Transport-Security max-age=31536000;
|
|
|
|
}
|
|
|
|
|
|
|
|
# .htaccess / data / config / ... shouldn't be accessible from outside
|
|
|
|
@forbidden {
|
|
|
|
path /.htaccess
|
|
|
|
path /data/*
|
|
|
|
path /config/*
|
|
|
|
path /db_structure
|
|
|
|
path /.xml
|
|
|
|
path /README
|
|
|
|
path /3rdparty/*
|
|
|
|
path /lib/*
|
|
|
|
path /templates/*
|
|
|
|
path /occ
|
|
|
|
path /console.php
|
|
|
|
}
|
|
|
|
respond @forbidden 404
|
|
|
|
|
|
|
|
|
|
|
|
@collabora {
|
|
|
|
path /browser/* # Browser is the client part of LibreOffice Online
|
|
|
|
path /hosting/discovery # WOPI discovery URL
|
|
|
|
path /hosting/capabilities # Show capabilities as json
|
|
|
|
path /cool/* # Main websocket, uploads/downloads, presentations
|
|
|
|
}
|
|
|
|
|
|
|
|
reverse_proxy @collabora collabora:9980 {
|
|
|
|
header_up Host "newcloud.kebler.net"
|
|
|
|
transport http {
|
|
|
|
tls_insecure_skip_verify
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
root * /var/www/html
|
|
|
|
php_fastcgi nextcloud-app:9000 {
|
|
|
|
env front_controller_active true # Remove index.php form url
|
|
|
|
root /var/www/html
|
|
|
|
}
|
|
|
|
file_server
|
|
|
|
}
|