Skip to content

Commit f383896

Browse files
committed
ci: 👷 dockerfile update
1 parent 916c583 commit f383896

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

‎config/deploy.yml‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,8 @@ builder:
6666
env:
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
#

‎next.config.js‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
module.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
{

0 commit comments

Comments
 (0)