build: add .dockerignore, optimize Dockerfile for limited memory
Build & Deploy Mobile / build-and-deploy (push) Failing after 42s
Build & Deploy Mobile / build-and-deploy (push) Failing after 42s
This commit is contained in:
+19
-4
@@ -1,5 +1,20 @@
|
|||||||
# Exclude source dev.db — live DB is on persistent volume at /app/data/dev.db
|
node_modules
|
||||||
prisma/dev.db*
|
.next
|
||||||
prisma/*.db-wal
|
.git
|
||||||
prisma/*.db-shm
|
.gitignore
|
||||||
|
*.md
|
||||||
|
*.log
|
||||||
.env
|
.env
|
||||||
|
.env.*
|
||||||
|
Dockerfile
|
||||||
|
.dockerignore
|
||||||
|
.gitkeep
|
||||||
|
**/*.test.ts
|
||||||
|
**/*.spec.ts
|
||||||
|
**/__tests__
|
||||||
|
tests
|
||||||
|
e2e
|
||||||
|
docs
|
||||||
|
.vscode
|
||||||
|
.idea
|
||||||
|
*.tsbuildinfo
|
||||||
|
|||||||
+2
-2
@@ -1,8 +1,8 @@
|
|||||||
FROM node:20-slim AS builder
|
FROM node:20-slim AS builder
|
||||||
RUN apt-get update && apt-get install -y --no-install-recommends openssl ca-certificates git && rm -rf /var/lib/apt/lists/*
|
RUN apt-get update && apt-get install -y --no-install-recommends openssl ca-certificates && rm -rf /var/lib/apt/lists/*
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY package.json package-lock.json* ./
|
COPY package.json package-lock.json* ./
|
||||||
RUN npm install --no-audit --no-fund
|
RUN npm cache clean --force 2>/dev/null; npm install --no-audit --no-fund --prefer-offline 2>/dev/null || npm install --no-audit --no-fund
|
||||||
COPY . .
|
COPY . .
|
||||||
RUN npx prisma generate --schema=./prisma/schema.prisma 2>/dev/null; exit 0
|
RUN npx prisma generate --schema=./prisma/schema.prisma 2>/dev/null; exit 0
|
||||||
RUN npm run build 2>/dev/null; exit 0
|
RUN npm run build 2>/dev/null; exit 0
|
||||||
|
|||||||
Reference in New Issue
Block a user