Browse Source

docker-config

fanxp 4 weeks ago
parent
commit
f0a01991cd
1 changed files with 13 additions and 11 deletions
  1. 13 11
      .drone.yml

+ 13 - 11
.drone.yml

@@ -64,28 +64,30 @@ node:
   mode: local_pre
 
 steps:
- - name: yarn-install
-   image: gplane/pnpm:node20
-   volumes:
-     - name: modules-cache
-       path: /drone/src/node_modules # 下载依赖的目录挂载出来,防止重复下载
-   commands:
-      - pnpm config set registry https://registry.npmmirror.com/
-      - pnpm install
-      - pnpm run build
+#  - name: yarn-install
+#    image: gplane/pnpm:node20
+#    volumes:
+#      - name: modules-cache
+#        path: /drone/src/node_modules # 下载依赖的目录挂载出来,防止重复下载
+#    commands:
+#       - pnpm config set registry https://registry.npmmirror.com/
+#       - pnpm install
+#       - pnpm run build
 
  - name: build
    image: docker:20.10.7
-   depends_on: [yarn-install]
+  #  depends_on: [yarn-install]
    volumes:
       - name: docker
         path: /var/run/docker.sock
+     - name: modules-cache
+       path: /drone/src/node_modules # 下载依赖的目录挂载出来,防止重复下载
    environment:
       IMAGE: registry.yingcaibx.com/tl/admin_web:latest
    commands:
       # 清理 docker 服务中不再使用的镜像、挂载、网络等资源
       - docker system prune --force --volumes || true
-      - docker build -f ./Dockerfile -t $IMAGE ./
+      - docker build -f ./Dockerfile-Dev -t $IMAGE ./
 
  - name: run
    image: docker/compose