docker file
This commit is contained in:
+3
-5
@@ -2,17 +2,15 @@ FROM node:22-alpine AS builder
|
|||||||
|
|
||||||
# Install tzdata to support timezone settings
|
# Install tzdata to support timezone settings
|
||||||
RUN apk add --no-cache tzdata
|
RUN apk add --no-cache tzdata
|
||||||
RUN npm install -g corepack@latest
|
|
||||||
RUN corepack enable && corepack prepare pnpm@10 --activate
|
|
||||||
|
|
||||||
# Set the timezone to Asia/Tehran
|
# Set the timezone to Asia/Tehran
|
||||||
RUN cp /usr/share/zoneinfo/Asia/Tehran /etc/localtime && echo "Asia/Tehran" > /etc/timezone
|
RUN cp /usr/share/zoneinfo/Asia/Tehran /etc/localtime && echo "Asia/Tehran" > /etc/timezone
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
COPY package*.json pnpm-lock.yaml ./
|
COPY package*.json ./
|
||||||
RUN pnpm install --frozen-lockfile --loglevel info
|
RUN npm ci --legacy-peer-deps
|
||||||
COPY . ./
|
COPY . ./
|
||||||
RUN pnpm run build
|
RUN npm run build
|
||||||
|
|
||||||
FROM nginx:stable-alpine AS production-stage
|
FROM nginx:stable-alpine AS production-stage
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user