Skip to content

Commit

Permalink
ci: test
Browse files Browse the repository at this point in the history
  • Loading branch information
besscroft committed Nov 27, 2024
1 parent cc1d750 commit 6dae6a1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
16 changes: 8 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:20.18-alpine3.19 AS base
FROM node:20.18-alpine3.19

WORKDIR /app

Expand All @@ -7,17 +7,17 @@ ENV NODE_ENV production
RUN addgroup --system --gid 1001 nodejs
RUN adduser --system --uid 1001 nextjs

COPY public ./app/public
COPY prisma ./app/prisma
COPY script.sh ./app/script.sh
COPY public /public
COPY prisma /prisma
COPY script.sh /script.sh
# Automatically leverage output traces to reduce image size
# https://nextjs.org/docs/advanced-features/output-file-tracing
COPY --chown=nextjs:nodejs .next/standalone ./app/
COPY --chown=nextjs:nodejs .next/static ./app/.next/static
COPY --chown=nextjs:nodejs .next/standalone /
COPY --chown=nextjs:nodejs .next/static /.next/static

RUN chmod +x ./app/script.sh
RUN chmod +x script.sh
#RUN mkdir .next
RUN chown nextjs:nodejs ./app/.next
RUN chown nextjs:nodejs .next

USER nextjs

Expand Down
3 changes: 1 addition & 2 deletions script.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#!/bin/sh

cd /app
npx prisma migrate deploy

HOSTNAME="0.0.0.0" node ./app/server.js
HOSTNAME="0.0.0.0" node server.js

0 comments on commit 6dae6a1

Please sign in to comment.