File tree Expand file tree Collapse file tree 2 files changed +68
-2
lines changed Expand file tree Collapse file tree 2 files changed +68
-2
lines changed Original file line number Diff line number Diff line change 18
18
- " git reset --hard origin/master --"
19
19
when : p.stat.isdir is defined and p.stat.isdir == True
20
20
21
- - name : Create project with managesf
22
- command : " sfmanager --auth admin:{{ authentication.admin_password }} --url http://{{ fqdn }} project create --name {{ project }}"
21
+ - name : " Reset config repos"
22
+ include : config_reset.yaml
23
+ when : p.stat.isdir is not defined
24
+
25
+ - hosts : install-server
26
+ tasks :
27
+ - name : Create project with the resources backend
28
+ template : src=../templates/project-resource.yaml.j2 dest=/root/config/resources/project-resource-{{ project }}.yaml
23
29
when : p.stat.isdir is not defined
24
30
31
+ - name : Commit change
32
+ command : chdir=/root/config {{ item }}
33
+ with_items :
34
+ - ' git add resources/project-resource-{{ project }}.yaml'
35
+ - ' git commit -a -m "Add {{ project }} to resources"'
36
+ environment : {'EDITOR':'test'}
37
+ when : p.stat.isdir is not defined
38
+
39
+ - name : " Submit config repos"
40
+ include : config_submit_change.yaml
41
+ when : p.stat.isdir is not defined
42
+
43
+ - hosts : install-server
44
+ tasks :
25
45
- name : Checkout project
26
46
git : repo=http://{{ fqdn }}/r/{{ project }} dest={{ project_path }}
27
47
when : p.stat.isdir is not defined
Original file line number Diff line number Diff line change
1
+ resources:
2
+ projects:
3
+ {{ project }}:
4
+ description: The project {{ project }}
5
+ issue-tracker: SFStoryboard
6
+ source-repositories:
7
+ - {{ project }}
8
+ repos:
9
+ {{ project }}:
10
+ description: The git repository {{ project }}
11
+ acl: config-acl
12
+ acls:
13
+ {{ project }}-acl:
14
+ file: |
15
+ [access "refs/*"]
16
+ read = group {{ project }}-core
17
+ owner = group {{ project }}-ptl
18
+ [access "refs/heads/*"]
19
+ label-Code-Review = -2..+2 group {{ project }}-core
20
+ label-Code-Review = -2..+2 group {{ project }}-ptl
21
+ label-Verified = -2..+2 group {{ project }}-ptl
22
+ label-Workflow = -1..+1 group {{ project }}-core
23
+ label-Workflow = -1..+1 group {{ project }}-ptl
24
+ label-Workflow = -1..+0 group Registered Users
25
+ submit = group {{ project }}-ptl
26
+ read = group {{ project }}-core
27
+ read = group Registered Users
28
+ [access "refs/meta/config"]
29
+ read = group {{ project }}-core
30
+ read = group Registered Users
31
+ [receive]
32
+ requireChangeId = true
33
+ [submit]
34
+ mergeContent = false
35
+ action = fast forward only
36
+ groups:
37
+ - {{ project }}-ptl
38
+ - {{ project }}-core
39
+ groups:
40
+ {{ project }}-ptl:
41
+ description: Team lead for the {{ project }} repo
42
+ members:
43
+
44
+ {{ project }}-core:
45
+ description: Team core for the {{ project }} repo
46
+ members: []
You can’t perform that action at this time.
0 commit comments