From 23977f74f5d111126ff6e3141b5c5b674cab9b46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Falc=C3=B3n?= Date: Mon, 4 May 2026 14:15:33 +0100 Subject: [PATCH] Fix Bun permissions for SSR worker (#349) ## Summary - install Bun under /usr/local/bun instead of /root/.bun - expose Bun via /usr/local/bin for www-data supervisor workers ## Test - docker build -f Dockerfile.production --check . --- Dockerfile.production | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Dockerfile.production b/Dockerfile.production index 85db95cd..06d7539c 100644 --- a/Dockerfile.production +++ b/Dockerfile.production @@ -32,9 +32,12 @@ COPY --from=composer:latest /usr/bin/composer /usr/bin/composer RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \ && apt-get install -y nodejs -# Install Bun -RUN curl -fsSL https://bun.com/install | bash -ENV PATH="/root/.bun/bin:${PATH}" +# Install Bun in a non-root path so supervisor workers running as www-data can execute it +ENV BUN_INSTALL="/usr/local/bun" +RUN curl -fsSL https://bun.com/install | bash \ + && ln -sf /usr/local/bun/bin/bun /usr/local/bin/bun \ + && chmod -R a+rx /usr/local/bun +ENV PATH="/usr/local/bun/bin:${PATH}" # Install memcached and redis servers RUN apt-get update && apt-get install -y memcached redis-server && rm -rf /var/lib/apt/lists/*