#!/bin/sh set -e # /app/data is usually a bind mount from the host, so whatever permissions the # image set during build don't survive. Fix ownership on boot, then drop root. if [ -d /app/data ]; then chown -R nextjs:nodejs /app/data 2>/dev/null || true fi exec su-exec nextjs:nodejs "$@"