-
Notifications
You must be signed in to change notification settings - Fork 1
/
cumulusci.yml
223 lines (202 loc) · 6.25 KB
/
cumulusci.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
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
minimum_cumulusci_version: 3.23.0
project:
name: Volunteers-for-Salesforce
package:
name: Volunteers for Salesforce
namespace: GW_Volunteers
api_version: "40.0"
install_class: InstallScript
git:
prefix_release: rel/
prefix_beta: beta/
repo_url: https://github.com/SalesforceFoundation/Volunteers-for-Salesforce
dependency_resolutions:
preproduction: include_beta
sources:
npsp:
github: https://github.com/SalesforceFoundation/NPSP
tasks:
deploy_dev_config:
description: Deploys the post install configuration for an unmanaged DE org
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/dev
deploy_qa_config:
description: Deploys the post install configuration for a regression or QA scratch org
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/qa
deploy_tab_config:
description: Deploys the post install configuration for custom tabs
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/tabs
deploy_v4s_only_page_layouts:
description: Deploys the page layouts for an org with Volunteers for Salesforce, but not NPSP
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/v4s_only_layouts
deploy_npsp_v4s_page_layouts:
description: Deploys the page layouts for an org with Volunteers for Salesforce and NPSP
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/npsp_v4s_layouts
deploy_delete_config:
description: Deploys the metadata deletions for the post install DE org config
class_path: cumulusci.tasks.salesforce.Deploy
options:
path: unpackaged/config/delete
deploy_package_settings:
description: Configure the default Volunteers Package Settings
class_path: cumulusci.tasks.apex.anon.AnonymousApexTask
options:
path: scripts/DeployScript.cls
apex: insertPackageSettings();
assign_pset:
description: Runs anonymous apex to assign pset for guest user.
class_path: cumulusci.tasks.apex.anon.AnonymousApexTask
options:
apex: >
Id psetId = [SELECT ID From PermissionSet WHERE Name = 'V4S_Site_Minimum' LIMIT 1][0].id;
Id guestId = [SELECT ID From User WHERE Name = 'Volunteers Site Guest User' LIMIT 1][0].id;
insert new PermissionSetAssignment(PermissionSetId=psetId, AssigneeId=guestId);
delete_data:
options:
objects:
- Volunteer_Hours__c
- Volunteer_Shift__c
- Job_Recurrence_Schedule__c
- Volunteer_Recurrence_Schedule__c
- Volunteer_Job__c
- Contact
- Account
- Campaign
ensure_record_type:
name: Ensure Campaign Record Types
description: This will ensure Record Types are enabled for the Campaign object in your org before installing Volunteers for Salesforce. If there are no Campaign record types yet, it will create one called Default.
class_path: cumulusci.tasks.salesforce.EnsureRecordTypes
options:
record_type_label: Default
record_type_developer_name: Default
sobject: Campaign
run_tests:
options:
retry_failures:
- "unable to obtain exclusive access to this record"
- "UNABLE_TO_LOCK_ROW"
- "connection was cancelled here"
retry_always: True
flows:
config_unmanaged:
steps:
1:
task: deploy_delete_config
2:
task: deploy_dev_config
3:
task: deploy_tab_config
4:
task: deploy_package_settings
when: '"GW_Volunteers" not in org_config.installed_packages'
5:
task: assign_pset
ignore_failure: True
6:
task: load_dataset
config_managed:
steps:
3:
task: deploy_tab_config
config_dev:
steps:
3:
flow: config_unmanaged
config_qa:
steps:
3:
flow: config_unmanaged
4:
task: deploy_qa_config
config_regression:
steps:
3:
flow: config_unmanaged
4:
task: deploy_qa_config
install_npsp:
steps:
1:
flow: npsp:install_prod
customer_org:
steps:
1:
task: ensure_record_type
ui_options:
name: Default Campaign Record Type
2:
task: install_managed
3:
task: deploy_tab_config
checks:
- when: "'GW_Volunteers' in tasks.get_installed_packages()" # Cached at start
action: "hide"
options:
unmanaged: False
ui_options:
name: "Install Volunteers for Salesforce Tabs"
4:
task: deploy_npsp_v4s_page_layouts
checks:
- when: "'npsp' not in tasks.get_installed_packages()"
action: hide
options:
unmanaged: False
ui_options:
name: "Install Page Layouts (NPSP)"
is_required: False
when: "org_config.has_minimum_package_version('npsp', '1.0')"
5:
task: deploy_v4s_only_page_layouts
checks:
- when: "'npsp' in tasks.get_installed_packages()"
action: hide
options:
unmanaged: False
ui_options:
name: "Install Page Layouts (V4S)"
is_required: False
when: "not org_config.has_minimum_package_version('npsp', '1.0')"
orgs:
scratch:
dev_namespaced:
config_file: orgs/dev.json
namespaced: True
days: 7
prerelease:
config_file: orgs/prerelease.json
plans:
install:
slug: install
title: Install Volunteers for Salesforce
tier: primary
is_listed: True
steps:
1:
flow: customer_org
upgrade:
slug: upgrade
title: Product Upgrade
tier: additional
is_listed: False
preflight_message: "This installer upgrades this package and any required dependencies to the latest version in your org. This installer isn't supported and has risks. Please don't run this installer unless you're aware of its specific use cases and considerations."
post_install_message: "Installation complete and package is on the latest version."
steps:
1:
task: update_dependencies
options:
security_type: PUSH
packages_only: True
2:
task: install_managed
options:
security_type: PUSH