Files
my_shop/entrypoint.sh

13 lines
357 B
Bash

#!/bin/sh
# Собираем статику
echo "Collecting static files..."
python manage.py collectstatic --noinput
# Применяем миграции базы данных
echo "Applying database migrations..."
python manage.py migrate --noinput
# Запускаем основную команду (Gunicorn)
echo "Starting Gunicorn..."
exec "$@"