加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
Dockerfile 810 Bytes
一键复制 编辑 原始数据 按行查看 历史
blade321 提交于 2024-01-10 10:19 . run container as user nginx
FROM gplane/pnpm as Builder
RUN mkdir -p /home/openeuler-certificate/web
WORKDIR /home/openeuler-certificate/web
COPY . /home/openeuler-certificate/web
RUN pnpm install
RUN pnpm build
# FROM nginx:1.20.0
# COPY ./deploy/test-login.html /usr/share/nginx/html/test-login.html
FROM swr.cn-north-4.myhuaweicloud.com/opensourceway/openeuler/nginx:1.22.0-22.03-lts
COPY --from=Builder /home/openeuler-certificate/web/dist/ /usr/share/nginx/html/
RUN chmod -R 755 /usr/share/nginx/html
COPY ./deploy/nginx/nginx.conf /etc/nginx/nginx.conf
ENV RUN_USER nginx
ENV RUN_GROUP nginx
RUN touch /var/run/nginx.pid \
&& chown -R nginx:nginx /var/log/nginx \
&& chown -R nginx:nginx /var/run/nginx.pid \
&& chown -R nginx:nginx /etc/nginx
EXPOSE 8080
USER nginx
ENTRYPOINT ["nginx", "-g", "daemon off;"]
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化