mirror of
https://github.com/umami-software/umami.git
synced 2026-02-13 17:15:37 +01:00
Update Dockerfile
This commit is contained in:
parent
ef0da264fc
commit
c3ca27b33b
1 changed files with 11 additions and 4 deletions
15
Dockerfile
15
Dockerfile
|
|
@ -34,10 +34,6 @@ ENV NODE_ENV=production
|
||||||
ENV NEXT_TELEMETRY_DISABLED=1
|
ENV NEXT_TELEMETRY_DISABLED=1
|
||||||
ENV NODE_OPTIONS=$NODE_OPTIONS
|
ENV NODE_OPTIONS=$NODE_OPTIONS
|
||||||
|
|
||||||
RUN echo "172.66.156.100 binaries.prisma.sh" >> /etc/hosts && \
|
|
||||||
echo "172.66.156.100 binaries.prisma.sh" >> /etc/hosts && \
|
|
||||||
echo "172.66.156.100 binaries.prisma.sh" >> /etc/hosts && \
|
|
||||||
echo "172.66.156.100 binaries.prisma.sh" >> /etc/hosts
|
|
||||||
RUN addgroup --system --gid 1001 nodejs
|
RUN addgroup --system --gid 1001 nodejs
|
||||||
RUN adduser --system --uid 1001 nextjs
|
RUN adduser --system --uid 1001 nextjs
|
||||||
RUN npm install -g pnpm
|
RUN npm install -g pnpm
|
||||||
|
|
@ -45,6 +41,17 @@ RUN npm install -g pnpm
|
||||||
RUN set -x \
|
RUN set -x \
|
||||||
&& apk add --no-cache curl
|
&& apk add --no-cache curl
|
||||||
|
|
||||||
|
RUN apk add --no-cache curl
|
||||||
|
RUN corepack enable && corepack prepare pnpm@latest --activate
|
||||||
|
|
||||||
|
# TẢI SẴN PRISMA BINARY TRONG BUILD → KHÔNG BAO GIỜ CẦN INTERNET LÚC MIGRATE
|
||||||
|
RUN mkdir -p /app/node_modules/.prisma/client
|
||||||
|
RUN wget -q https://binaries.prisma.sh/all_commits/34b5a692b7bd79939a9a2c3ef97d816e749cda2f/linux-musl-openssl-3.0.x/query-engine.gz \
|
||||||
|
-O /app/node_modules/.prisma/client/query-engine.gz && \
|
||||||
|
wget -q https://binaries.prisma.sh/all_commits/34b5a692b7bd79939a9a2c3ef97d816e749cda2f/linux-musl-openssl-3.0.x/schema-engine.gz \
|
||||||
|
-O /app/node_modules/.prisma/client/schema-engine.gz && \
|
||||||
|
gunzip /app/node_modules/.prisma/client/*.gz && \
|
||||||
|
chmod +x /app/node_modules/.prisma/client/query-engine*
|
||||||
# Script dependencies
|
# Script dependencies
|
||||||
RUN pnpm add npm-run-all dotenv chalk semver prisma@6.18.0 @prisma/adapter-pg@6.18.0
|
RUN pnpm add npm-run-all dotenv chalk semver prisma@6.18.0 @prisma/adapter-pg@6.18.0
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue