-
Notifications
You must be signed in to change notification settings - Fork 7
/
.drone-ci.yml
77 lines (69 loc) · 1.65 KB
/
.drone-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
---
kind: pipeline
type: kubernetes
name: ci
clone:
depth: 1
disable: true
steps:
- name: 获取代码
image: ccr.ccs.tencentyun.com/easycorp/drone-plugin-git
pull: always
settings:
depth: 1
branch: ${DRONE_BRANCH}
url: [email protected]:pangu/qucheng.git
- name: 构建镜像
image: ccr.ccs.tencentyun.com/easycorp/drone-plugin-builderx
volumes:
- name: dockersock
path: /var/run
pull: always
privileged: true
settings:
registry: hub.qucheng.com
repo: hub.qucheng.com/platform/qucheng
debug: true
mode: ${DRONE_BRANCH}
# auto_tag: true
# auto_tag_suffix: "${DRONE_BRANCH}-"
tags: ${DRONE_BRANCH}
purge: false
no_cache: false
dockerfile: "docker/Dockerfile"
- name: 开发环境更新
image: ccr.ccs.tencentyun.com/easycorp/drone-plugin-kubectl
pull: always
settings:
debug: false
cmd: "kubectl rollout restart deploy/qucheng -n cne-system"
env: "dev"
when:
branch:
- master
- name: 测试环境更新
image: ccr.ccs.tencentyun.com/easycorp/drone-plugin-kubectl
pull: always
settings:
debug: false
cmd: "kubectl rollout restart deploy/qucheng -n cne-system"
env: "pre"
when:
branch:
- test
services:
- name: docker daemon
image: ccr.ccs.tencentyun.com/easycorp/drone-plugin-dockerd
privileged: true
volumes:
- name: dockersock
path: /var/run
volumes:
- name: dockersock
temp: {}
node_selector:
workload_type: "spot"
tolerations:
- key: ci.zcorp.cc
operator: Exists
effect: NoSchedule