37 lines
893 B
Caddyfile
37 lines
893 B
Caddyfile
{
|
|
email soporte@rodax-software.com
|
|
auto_https disable_redirects
|
|
}
|
|
|
|
|
|
https://presupuestos.uecko.com:13001 {
|
|
reverse_proxy backend:3001
|
|
encode gzip # Comprime las respuestas con gzip
|
|
}
|
|
|
|
:443 {
|
|
root * /srv
|
|
|
|
# Los bundles con hash son inmutables. Un bundle inexistente debe dar 404,
|
|
# nunca el HTML de la SPA (que no es un módulo JavaScript).
|
|
handle /assets/* {
|
|
@existing file
|
|
@missing not file
|
|
header @existing Cache-Control "public, max-age=31536000, immutable"
|
|
header @missing Cache-Control "no-cache"
|
|
file_server
|
|
}
|
|
|
|
handle /version.json {
|
|
header Cache-Control "no-store"
|
|
file_server
|
|
}
|
|
|
|
handle {
|
|
# También se aplica al HTML servido para /quotes, /login, etc.
|
|
header Cache-Control "no-cache"
|
|
try_files {path} /index.html
|
|
file_server
|
|
}
|
|
}
|