test/.drone.yml
admin 7440d1ed60
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone Build is passing
更新 .drone.yml
2025-05-09 02:05:14 +00:00

63 lines
1.3 KiB
YAML

kind: pipeline
type: docker
name: pipeline-1
clone:
disable: true
workspace:
path: /drone/src/${DRONE_BUILD_NUMBER}
steps:
- name: clone
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/alpine/git:latest
commands:
- git clone -b main http://root:rootroot@115.190.73.171:3000/admin/test.git
- ls -la /drone/src/
- ls -la /drone/src/${DRONE_BUILD_NUMBER}
- sleep 1m
- name: build
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/gcr.io/iguazio/alpine:3.17
commands:
- cd $DRONE_WORKSPACE
- pwd
- ls -la /drone/src/
- ls -la /drone/src/${DRONE_BUILD_NUMBER}
- sleep 1m
# - name: publish
# image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/gcr.io/iguazio/alpine:3.17
# commands:
# - cd $DRONE_WORKSPACE
# - pwd
# - ls -la /drone/src/
# - ls -la /drone/src/${DRONE_BUILD_NUMBER}
# depends_on:
# - clone
# - build
node:
app: build
---
kind: pipeline
type: docker
name: pipeline-2
depends_on:
- pipeline-1
clone:
disable: true
steps:
- name: deploy
image: swr.cn-north-4.myhuaweicloud.com/ddn-k8s/gcr.io/iguazio/alpine:3.17
commands:
- echo "===== Drone 相关变量 ====="
- env | grep DRONE_
- echo "===== 路径变量 ====="
- env | grep PATH
node:
app: mvn