-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpoulpe.gocd.yaml
97 lines (97 loc) · 2.9 KB
/
poulpe.gocd.yaml
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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
format_version: 10
pipelines:
poulpe-docker:
group: ztec.fr
label_template: ${COUNT}
lock_behavior: none
display_order: -1
materials:
poulpe:
git: ssh://git@git.riper.fr:22023/ztec/poulpe.git
shallow_clone: false
auto_update: true
branch: main
stages:
- build:
fetch_materials: true
keep_artifacts: false
clean_workspace: false
approval:
type: success
allow_only_on_success: false
jobs:
build-docker:
timeout: 0
resources:
- docker
tasks:
- exec:
arguments:
- -c
- docker build -t git2.riper.fr/ztec/poulpe:$GO_PIPELINE_LABEL .
command: /bin/bash
run_if: passed
- exec:
arguments:
- -c
- docker build -t git2.riper.fr/ztec/poulpe:latest .
command: /bin/bash
run_if: passed
artifacts:
- external:
id: poulpe-img
store_id: ztec
configuration:
options:
Image: git2.riper.fr/ztec/poulpe
Tag: ${GO_PIPELINE_LABEL}
- external:
id: poulpe-latest
store_id: ztec
configuration:
options:
Image: git2.riper.fr/ztec/poulpe
Tag: latest
poulpe-deploy:
group: ztec.fr
label_template: ${COUNT}
lock_behavior: none
display_order: -1
materials:
poulpe-docker:
ignore_for_scheduling: false
pipeline: poulpe-docker
stage: build
poulpe:
git: ssh://git@git.riper.fr:22023/ztec/poulpe.git
shallow_clone: false
auto_update: true
branch: main
stages:
- deploy:
fetch_materials: true
keep_artifacts: false
clean_workspace: false
approval:
type: success
allow_only_on_success: false
jobs:
helm-update:
timeout: 0
resources:
- docker
- kubectl
tasks:
- fetch:
artifact_id: poulpe-img
pipeline: poulpe-docker
stage: build
job: build-docker
artifact_origin: external
run_if: passed
- exec:
arguments:
- -c
- helm3 upgrade --install --wait --set-string image.name="$ARTIFACT_IMAGE" poulpe ./helm -f helm/values.yaml --wait
command: /bin/bash
run_if: passed