This commit is contained in:
parent
adb7b2cf3f
commit
9cef9fe8d8
@ -72,7 +72,7 @@ steps:
|
|||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
target: release
|
target: release
|
||||||
cache_from:
|
cache_from:
|
||||||
- docker-registry.ivanli.cc/ivan/tailwind-nextjs-blog-base:${DRONE_BRANCH}${DRONE_TAG}-amd64
|
- docker-registry.ivanli.cc/ivan/tailwind-nextjs-blog:${DRONE_BRANCH}${DRONE_TAG}-amd64
|
||||||
tags:
|
tags:
|
||||||
- '${DRONE_COMMIT_SHA:0:8}'
|
- '${DRONE_COMMIT_SHA:0:8}'
|
||||||
- '${DRONE_BRANCH}${DRONE_TAG}'
|
- '${DRONE_BRANCH}${DRONE_TAG}'
|
||||||
|
@ -4,12 +4,12 @@ WORKDIR /app
|
|||||||
COPY pnpm-lock.yaml package.json ./
|
COPY pnpm-lock.yaml package.json ./
|
||||||
RUN npm i --location=global pnpm@7 &&\
|
RUN npm i --location=global pnpm@7 &&\
|
||||||
pnpm i
|
pnpm i
|
||||||
|
COPY . .
|
||||||
|
RUN pnpm build &&\
|
||||||
|
pnpm prune --prod
|
||||||
|
|
||||||
FROM node:16-alpine as release
|
FROM node:16-alpine as release
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY . .
|
|
||||||
COPY --from=base /app ./
|
COPY --from=base /app ./
|
||||||
RUN pnpm build &&\
|
|
||||||
pnpm prune --prod
|
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
CMD pnpm serve -p 80
|
CMD pnpm serve -p 80
|
Loading…
Reference in New Issue
Block a user