-
Notifications
You must be signed in to change notification settings - Fork 24
/
Copy pathpipeline-parameterized.yml
173 lines (158 loc) · 4.44 KB
/
pipeline-parameterized.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
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
resource_types:
- name: pivnet
type: docker-image
source:
repository: pivotalcf/pivnet-resource
tags: latest-final
resources:
- name: pcf-automation
type: pivnet
source:
api_token: {{pivnet_api_token}}
product_slug: platform-automation
- name: configuration
type: git
source:
uri: {{automation_repo}}
# private_key: {{git_private_key}}
- name: credentials
type: git
source:
uri: {{automation_private_repo}}
private_key: {{git_private_key}}
jobs:
- name: ((foundation))-((pivnet_product_slug))
serial: true
plan:
- aggregate:
- get: configuration
trigger: false
params:
unpack: true
- get: pcf-automation-image
resource: pcf-automation
params:
unpack: true
globs: ["*image*"]
- get: pcf-automation-tasks
resource: pcf-automation
params:
unpack: true
globs: ["*tasks*"]
- get: credentials
params:
unpack: true
- task: vars-interpolate
image: pcf-automation-image
file: configuration/fixes/tasks/vars-interpolate.yml
input_mapping:
config: configuration
vars: credentials
params:
VARS_FILES: vars/((foundation))/common.yml
CONFIG_FILE: config/templates/env.yml
output_mapping:
interpolated-files: configuration
- task: download-product
image: pcf-automation-image
file: configuration/fixes/tasks/download-product.yml
input_mapping:
config: configuration
secrets: credentials
params:
CONFIG_FILE: config/templates/pivnet.yml
VARS_FILES: secrets/((foundation))/common.yml secrets/((foundation))/((pivnet_product_slug)).yml
- task: upload-product
image: pcf-automation-image
file: pcf-automation-tasks/tasks/upload-product.yml
input_mapping:
product: downloaded-product
env: configuration
params:
ENV_FILE: config/templates/env.yml
- task: stage-product
image: pcf-automation-image
file: pcf-automation-tasks/tasks/stage-product.yml
input_mapping:
product: downloaded-product
env: configuration
params:
ENV_FILE: config/templates/env.yml
- task: upload-stemcell
image: pcf-automation-image
file: pcf-automation-tasks/tasks/upload-stemcell.yml
input_mapping:
env: configuration
stemcell: downloaded-stemcell
params:
ENV_FILE: config/templates/env.yml
- task: assign-stemcell
image: pcf-automation-image
file: pcf-automation-tasks/tasks/assign-stemcell.yml
input_mapping:
env: configuration
config: assign-stemcell-config
params:
ENV_FILE: config/templates/env.yml
- task: params-interpolate
image: pcf-automation-image
file: configuration/fixes/tasks/params-interpolate.yml
input_mapping:
config: tile-config
vars: credentials
params:
VARS_FILES: vars/((foundation))/common.yml vars/((foundation))/((pivnet_product_slug)).yml
output_mapping:
interpolated-files: tile-config
- task: configure-product
image: pcf-automation-image
file: pcf-automation-tasks/tasks/configure-product.yml
input_mapping:
config: tile-config
env: configuration
vars: tile-config
secrets: credentials
params:
CONFIG_FILE: ((config_file))
VARS_FILES: ((vars_files)) secrets/((foundation))/common.yml secrets/((foundation))/((pivnet_product_slug)).yml
ENV_FILE: config/templates/env.yml
- name: apply-changes
serial: true
plan:
- aggregate:
- get: configuration
trigger: false
passed: [ ((foundation))-((pivnet_product_slug)) ]
params:
unpack: true
- get: pcf-automation-image
resource: pcf-automation
params:
unpack: true
globs: ["*image*"]
- get: pcf-automation-tasks
resource: pcf-automation
params:
unpack: true
globs: ["*tasks*"]
- get: credentials
params:
unpack: true
- task: vars-interpolate
image: pcf-automation-image
file: configuration/fixes/tasks/vars-interpolate.yml
input_mapping:
config: configuration
vars: credentials
params:
VARS_FILES: vars/((foundation))/common.yml
CONFIG_FILE: config/templates/env.yml
output_mapping:
interpolated-files: configuration
- task: apply-product-changes
image: pcf-automation-image
file: pcf-automation-tasks/tasks/apply-changes.yml
input_mapping:
env: configuration
params:
ENV_FILE: config/templates/env.yml