Files
blog-frontend-v2/Dockerfile
passthem 345d8218a0
All checks were successful
continuous-integration/drone/push Build is passing
添加一个 init 进程
2026-03-27 03:27:01 +08:00

22 lines
293 B
Docker

FROM node:lts-alpine AS runtime
WORKDIR /app
# 提供一个很小很小的 init 进程
RUN apk add --no-cache tini
COPY package*.json .
RUN npm install
COPY . .
RUN npm run build
ENV HOST=0.0.0.0
ENV PORT=4321
ENTRYPOINT [ "/sbin/tini", "--" ]
CMD ["node", "./dist/server/entry.mjs"]