代码拉取完成,页面将自动刷新
FROM node:18.19-alpine3.18 as builder
COPY . /hellworld-blog
WORKDIR /hellworld-blog
RUN yarn install --no-frozen-lockfile --registry=https://registry.npm.taobao.org
RUN yarn build
# deploy flygoose web
FROM node:18.19-alpine3.18
RUN npm install -g pm2 --registry=https://registry.npm.taobao.org
RUN adduser -D -u 6666 www
RUN mkdir -p /apps/hellworld-blog ; chown -R www /apps/hellworld-blog/
USER www
#copy flygoose web
COPY --from=builder /hellworld-blog/node_modules /apps/hellworld-blog/node_modules
COPY --from=builder /hellworld-blog/nuxt.config.ts /apps/hellworld-blog/
COPY --from=builder /hellworld-blog/package.json /apps/hellworld-blog/
COPY --from=builder /hellworld-blog/pm2.config.js /apps/hellworld-blog/
COPY --from=builder /hellworld-blog/server /apps/hellworld-blog/server
COPY --from=builder /hellworld-blog/.nuxt /apps/hellworld-blog/.nuxt
COPY --from=builder /hellworld-blog/.output /apps/hellworld-blog/.output
WORKDIR /apps/hellworld-blog/
EXPOSE 58081
CMD ["sh", "-c", "pm2 start pm2.config.js ; pm2 logs"]
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。