Fix data dir permissions and legal doc links

- Dockerfile: create /app/data owned by nextjs before USER switch so fresh
  deployments work without manual chown. Existing servers need:
    sudo chown -R 1001:1001 estore/data
- nav.js: fix footer legal links to point to /shop/privacy|terms|refund
  (pages live in estore, not main site)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
chris 2026-04-15 13:28:20 -04:00
parent 215a8f2e3f
commit f4b1f7722e
2 changed files with 8 additions and 3 deletions

View File

@ -38,6 +38,11 @@ COPY --from=builder /app/public ./public
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
# Ensure the data directory exists and is writable by the nextjs user.
# For bind-mount deployments, the host directory must also be owned by uid 1001:
# sudo chown -R 1001:1001 estore/data
RUN mkdir -p /app/data && chown nextjs:nodejs /app/data
USER nextjs
EXPOSE 3000
ENV PORT=3000

View File

@ -51,11 +51,11 @@
' <p>Copyright &copy; ' + new Date().getFullYear() + ' Beach Party Balloons</p>\n' +
' <p>All images &amp; content are property of Beach Party Balloons. Use of images without written permission is prohibited.</p>\n' +
' <p style="font-size:0.8rem;margin-top:0.5rem">\n' +
' <a href="/privacy/">Privacy Policy</a>\n' +
' <a href="/shop/privacy">Privacy Policy</a>\n' +
' &nbsp;&middot;&nbsp;\n' +
' <a href="/terms/">Terms of Service</a>\n' +
' <a href="/shop/terms">Terms of Service</a>\n' +
' &nbsp;&middot;&nbsp;\n' +
' <a href="/refund/">Refund &amp; Cancellation Policy</a>\n' +
' <a href="/shop/refund">Refund &amp; Cancellation Policy</a>\n' +
' </p>\n' +
' </div>\n' +
'</footer>';