more fixes

This commit is contained in:
Tobias Brunner 2025-01-30 19:09:04 +01:00
parent 6f43d339b8
commit 2c751294da
No known key found for this signature in database
2 changed files with 12 additions and 3 deletions

View file

@ -5,7 +5,10 @@ WORKDIR /app
ENV PATH="/app/.venv/bin:$PATH" ENV PATH="/app/.venv/bin:$PATH"
ENV STATIC_ROOT=/app/staticfiles ENV STATIC_ROOT=/app/staticfiles
ENV MEDIA_ROOT=/app/mediafiles ENV MEDIA_ROOT=/data/media
# Set Caddy's XDG base directory to a writable location
ENV XDG_DATA_HOME=/app/run/caddy/data
ENV XDG_CONFIG_HOME=/app/run/caddy/config
# Install system dependencies including Caddy # Install system dependencies including Caddy
RUN apt-get update && apt-get install -y \ RUN apt-get update && apt-get install -y \

View file

@ -1,8 +1,10 @@
{ {
admin off admin on
auto_https off auto_https off
http_port 8080 http_port 8080
https_port 0 https_port 0
cert_issuer internal
skip_install_trust
log { log {
output stderr output stderr
@ -10,6 +12,10 @@
level INFO level INFO
} }
servers {
protocols h1
}
storage file_system { storage file_system {
root /app/run/caddy root /app/run/caddy
} }
@ -31,7 +37,7 @@
# Handle media files # Handle media files
handle /media/* { handle /media/* {
uri strip_prefix /media uri strip_prefix /media
root * /app/mediafiles root * /data/media
file_server file_server
} }