|
|
@ -17,36 +17,36 @@ volumes: |
|
|
|
path: /var/lib/data |
|
|
|
|
|
|
|
steps: |
|
|
|
- name: restore-cache |
|
|
|
image: drillster/drone-volume-cache |
|
|
|
volumes: |
|
|
|
- name: cache |
|
|
|
path: /cache |
|
|
|
settings: |
|
|
|
restore: true |
|
|
|
mount: |
|
|
|
- ./node_modules |
|
|
|
# - name: restore-cache |
|
|
|
# image: drillster/drone-volume-cache |
|
|
|
# volumes: |
|
|
|
# - name: cache |
|
|
|
# path: /cache |
|
|
|
# settings: |
|
|
|
# restore: true |
|
|
|
# mount: |
|
|
|
# - ./node_modules |
|
|
|
|
|
|
|
- name: build |
|
|
|
image: node:latest |
|
|
|
pull: if-not-exists # default always |
|
|
|
volumes: |
|
|
|
- name: cache |
|
|
|
path: /root/.m2 |
|
|
|
# volumes: |
|
|
|
# - name: cache |
|
|
|
# path: /root/.m2 |
|
|
|
commands: |
|
|
|
- npm config set registry http://registry.npm.taobao.org |
|
|
|
- npm i |
|
|
|
- npm run build:dev |
|
|
|
- npm run test |
|
|
|
|
|
|
|
- name: rebuild-cache |
|
|
|
image: drillster/drone-volume-cache |
|
|
|
volumes: |
|
|
|
- name: cache |
|
|
|
path: /cache |
|
|
|
settings: |
|
|
|
rebuild: true |
|
|
|
mount: |
|
|
|
- ./node_modules |
|
|
|
# - name: rebuild-cache |
|
|
|
# image: drillster/drone-volume-cache |
|
|
|
# volumes: |
|
|
|
# - name: cache |
|
|
|
# path: /cache |
|
|
|
# settings: |
|
|
|
# rebuild: true |
|
|
|
# mount: |
|
|
|
# - ./node_modules |
|
|
|
|
|
|
|
- name: deploy-scp |
|
|
|
image: appleboy/drone-scp |
|
|
|