You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .cm/SecurityManager.cm
+29-5Lines changed: 29 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -9,28 +9,52 @@ automations:
9
9
- action: add-comment@v1
10
10
args:
11
11
comment: |
12
-
PR: {{ pr | dump | safe }}
12
+
comments: {{ pr.comments | dump | safe }}
13
13
14
14
Security_comment:
15
15
if:
16
16
- {{ jit.metrics.HIGH > 0 }}
17
-
- {{ pr.conversations | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='This PR failed due to High severity vulnerability finding') | nope }}
17
+
- {{ pr.conversations | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='This PR failed due to High severity vulnerability finding, if you don`t fix it please select:') | nope }}
18
18
run:
19
19
- action: add-comment@v1
20
20
args:
21
21
comment: |
22
-
This PR failed due to High severity vulnerability finding, if you don`t fix it please select:
22
+
This PR failed due to High severity vulnerability finding, if you don't fix it please select:
23
23
- [ ] I need help with that fix.
24
24
- [ ] I want to accept the risk, please approve.
25
25
- [ ] This is false positive, please approve.
26
26
- [ ] This is a test / simulator environment, please exclude.
27
27
28
-
Security_comment_response:
28
+
Security_comment_need_help:
29
29
if:
30
-
- {{ pr.conversations | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='- [x] I need help with that fix.') | some}}
30
+
- {{ pr.comments | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='- [x] I need help with that fix.') | some}}
31
31
run:
32
32
- action: add-label@v1
33
33
args:
34
34
label: "Fix pending"
35
35
36
+
Security_comment_accept_risk:
37
+
if:
38
+
- {{ pr.comments | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='- [x] I want to accept the risk, please approve.') | some}}
39
+
run:
40
+
- action: add-label@v1
41
+
args:
42
+
label: "Accept risk"
43
+
44
+
Security_comment_false_positive:
45
+
if:
46
+
- {{ pr.comments | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='- [x] This is false positive, please approve.') | some}}
47
+
run:
48
+
- action: add-label@v1
49
+
args:
50
+
label: "False positive"
51
+
52
+
Security_comment_test_env:
53
+
if:
54
+
- {{ pr.comments | filter(attr='commenter', term='gitstream-cm') | filter (attr='content', term='- [x] This is a test / simulator environment, please exclude.') | some}}
0 commit comments