File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -252,12 +252,14 @@ COPY --from=builder --chown=nextjs:nodejs /app/apps/sim/lib/execution/sandbox/bu
252252# - apps/sim/.next/cache: the Next image optimizer's disk cache
253253# (.next/cache/images) and the data cache for `fetch` calls with
254254# `next.revalidate`.
255+ # - apps/sim/.next/server/route-cache: where Next writes every revalidated
256+ # (ISR) page and route handler response.
255257# Keep the VOLUME line after every step that writes to these paths: the
256258# classic builder discards later build-time changes to a declared volume.
257- RUN mkdir -p apps/sim/.next/cache && \
258- chown -R nextjs:nodejs apps/sim/.next/cache && \
259+ RUN mkdir -p apps/sim/.next/cache apps/sim/.next/server/route-cache && \
260+ chown -R nextjs:nodejs apps/sim/.next/cache apps/sim/.next/server/route-cache && \
259261 chmod 1777 /tmp
260- VOLUME ["/tmp" , "/app/apps/sim/.next/cache" ]
262+ VOLUME ["/tmp" , "/app/apps/sim/.next/cache" , "/app/apps/sim/.next/server/route-cache" ]
261263
262264# Switch to non-root user
263265USER nextjs
Original file line number Diff line number Diff line change @@ -46,7 +46,11 @@ COPY --chown=pii:pii --chmod=755 docker/pii-entrypoint.sh ./
4646# and /tmp (mode 1777), Python's tempfile scratch, stays writable because ECS
4747# copies the image's /tmp into a bind volume mounted at a VOLUME path. The
4848# VOLUME line stays below the model download, which stages wheels in /tmp.
49- ENV PYTHONDONTWRITEBYTECODE=1
49+ # tldextract (pulled in by Presidio) caches the Public Suffix List under
50+ # $HOME/.cache by default; point it at /tmp so it caches instead of
51+ # refetching the list on every start.
52+ ENV PYTHONDONTWRITEBYTECODE=1 \
53+ TLDEXTRACT_CACHE=/tmp/tldextract
5054RUN chmod 1777 /tmp
5155VOLUME ["/tmp" ]
5256
You can’t perform that action at this time.
0 commit comments