Files
dsp/docker/app-entrypoint.sh
2026-01-29 14:31:48 +07:00

13 lines
368 B
Bash

#!/bin/bash
set -e
# Ensure uploads subdirectories exist and are writable
UPLOAD_ROOT="/var/www/html/uploads"
mkdir -p "$UPLOAD_ROOT/announcements" "$UPLOAD_ROOT/slides" "$UPLOAD_ROOT/datasources"
# Relax permissions so Apache (www-data) can write when using bind mounts
chown -R www-data:www-data "$UPLOAD_ROOT"
chmod -R 775 "$UPLOAD_ROOT"
exec apache2-foreground