mirror of
https://github.com/mealie-recipes/mealie.git
synced 2025-07-09 03:04:54 -04:00
Refactor/class based gunicorn conf (#608)
* use class for conf * format caddy file Co-authored-by: hay-kot <hay-kot@pm.me>
This commit is contained in:
parent
8a2ed0bd78
commit
b54a7d4fcc
53
Caddyfile
53
Caddyfile
@ -1,35 +1,34 @@
|
||||
{
|
||||
auto_https off
|
||||
admin off
|
||||
admin off
|
||||
}
|
||||
|
||||
:80 {
|
||||
@proxied path /api/* /docs /openapi.json
|
||||
@proxied path /api/* /docs /openapi.json
|
||||
|
||||
@static {
|
||||
file
|
||||
path *.ico *.css *.js *.gif *.jpg *.jpeg *.png *.svg *.woff *.woff2 *.webp
|
||||
}
|
||||
|
||||
encode gzip zstd
|
||||
|
||||
|
||||
# Handles Recipe Images / Assets
|
||||
handle_path /api/media/recipes/* {
|
||||
header @static Cache-Control max-age=31536000
|
||||
root * /app/data/recipes/
|
||||
file_server
|
||||
}
|
||||
@static {
|
||||
file
|
||||
path *.ico *.css *.js *.gif *.jpg *.jpeg *.png *.svg *.woff *.woff2 *.webp
|
||||
}
|
||||
|
||||
handle @proxied {
|
||||
uri strip_suffix /
|
||||
reverse_proxy http://127.0.0.1:9000
|
||||
}
|
||||
encode gzip zstd
|
||||
|
||||
handle {
|
||||
header @static Cache-Control max-age=31536000
|
||||
root * /app/dist
|
||||
try_files {path}.html {path} /
|
||||
file_server
|
||||
}
|
||||
}
|
||||
# Handles Recipe Images / Assets
|
||||
handle_path /api/media/recipes/* {
|
||||
header @static Cache-Control max-age=31536000
|
||||
root * /app/data/recipes/
|
||||
file_server
|
||||
}
|
||||
|
||||
handle @proxied {
|
||||
uri strip_suffix /
|
||||
reverse_proxy http://127.0.0.1:9000
|
||||
}
|
||||
|
||||
handle {
|
||||
header @static Cache-Control max-age=31536000
|
||||
root * /app/dist
|
||||
try_files {path}.html {path} /
|
||||
file_server
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user