123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- kind: pipeline
- name: default
- steps:
- - name: restore-cache
- image: drillster/drone-volume-cache
- volumes:
- - name: cache
- path: /cache
- settings:
- restore: true
- mount:
- - ./node_modules
- - name: build
- image: node:12-alpine
- commands:
- - npm install -g cnpm --registry=https://registry.npm.taobao.org
- - cnpm install
- - cnpm install core-js
- - cnpm run build:prod
- - name: rebuild-cache
- image: drillster/drone-volume-cache
- volumes:
- - name: cache
- path: /cache
- settings:
- rebuild: true
- mount:
- - ./node_modules
- - name: docker
- image: plugins/docker
- settings:
- tags:
- - latest
- - 1.0.${DRONE_BUILD_NUMBER}
- registry: nas.fast-fun.cn:5000
- insecure: true
- repo: nas.fast-fun.cn:5000/zhl/pdms-oss-ui
- - name: deploy
- image: appleboy/drone-ssh
- settings:
- host: 192.168.0.41
- username: zhl
- password: 123456
- script:
- - docker rm -f oss-ui
- - docker rmi -f nas.fast-fun.cn:5000/zhl/pdms-oss-ui
- - docker run -d --name oss-api --link pdms-oss-api:pdms-oss-api -l traefik.port=80 nas.fast-fun.cn:5000/zhl/pdms-oss-ui
- volumes:
- - name: cache
- host:
- path: /home/drone/cache
|