File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -66,7 +66,8 @@ builder:
6666env :
6767 clear :
6868 NODE_ENV : production # Set to 'production' for production deployments
69-
69+ # Bypass Next.js image optimization so images work behind the proxy (see next.config.js)
70+ NEXT_IMAGE_UNOPTIMIZED : ' true'
7071# Use a different ssh user than root
7172# Uncomment and configure if you need to use a non-root user for SSH access
7273#
Original file line number Diff line number Diff line change 11module . exports = {
22 reactStrictMode : true ,
33 images : {
4+ // In Docker behind a reverse proxy (e.g. Kamal), the /_next/image endpoint can
5+ // fail (timeouts, wrong host, or container can't fetch remote URLs). Set
6+ // NEXT_IMAGE_UNOPTIMIZED=true in the container env to serve images directly.
7+ unoptimized : process . env . NEXT_IMAGE_UNOPTIMIZED === 'true' ,
48 dangerouslyAllowSVG : true ,
59 remotePatterns : [
610 {
You can’t perform that action at this time.
0 commit comments