fix dockerfile: use bun instead of npm, add .dockerignore
This commit is contained in:
11
.dockerignore
Normal file
11
.dockerignore
Normal file
@@ -0,0 +1,11 @@
|
||||
node_modules
|
||||
dist
|
||||
dist-ssr
|
||||
.git
|
||||
.gitignore
|
||||
*.log
|
||||
*.local
|
||||
.vscode
|
||||
.idea
|
||||
.DS_Store
|
||||
README.md
|
||||
@@ -1,12 +1,12 @@
|
||||
# Stage 1: Build
|
||||
FROM node:20-alpine AS build
|
||||
FROM oven/bun:1 AS build
|
||||
WORKDIR /app
|
||||
COPY package.json bun.lock ./
|
||||
RUN npm install
|
||||
RUN bun install --frozen-lockfile
|
||||
COPY . .
|
||||
ARG VITE_NKODE_API_URL=https://api.nkode.donovankelly.xyz
|
||||
ENV VITE_NKODE_API_URL=$VITE_NKODE_API_URL
|
||||
RUN npm run build
|
||||
RUN bun run build
|
||||
|
||||
# Stage 2: Serve
|
||||
FROM nginx:alpine
|
||||
|
||||
Reference in New Issue
Block a user