File tree Expand file tree Collapse file tree 5 files changed +29
-11
lines changed Expand file tree Collapse file tree 5 files changed +29
-11
lines changed Original file line number Diff line number Diff line change @@ -40,25 +40,43 @@ This extension requires that Node.js and npm be installed on the build agent. Th
40
40
### Simple Application Testing Example
41
41
42
42
```
43
- - task: SnykSecurityScan@0
43
+ - task: SnykSecurityScan@1
44
44
inputs:
45
45
serviceConnectionEndpoint: 'mySnykToken'
46
46
testType: 'app'
47
- monitorWhen: 'always'
48
47
failOnIssues: true
48
+ monitorWhen: 'always'
49
+ ```
50
+
51
+ ### If you do not want the Snyk task fail your pipeline when issues are found, but still want to monitor the results in the Snyk UI
52
+
53
+ To do this, you need to:
54
+
55
+ - set ` failOnIssues ` to ` false ` , which will make sure the Snyk task will not fail your pipeline even if issues (vulnerabilities, etc) are found
56
+ - have ` monitorWhen ` set to ` always ` (or just leave ` monitorWhen ` out, since ` always ` is the default)
57
+
58
+ Here's a full example:
59
+
60
+ ```
61
+ - task: SnykSecurityScan@1
62
+ inputs:
63
+ serviceConnectionEndpoint: 'mySnykToken'
64
+ testType: 'app'
65
+ failOnIssues: false
66
+ monitorWhen: 'always'
49
67
```
50
68
51
69
### Simple Container Image Testing Example
52
70
53
71
```
54
- - task: SnykSecurityScan@0
72
+ - task: SnykSecurityScan@1
55
73
inputs:
56
74
serviceConnectionEndpoint: 'mySnykToken'
57
75
testType: 'container'
58
76
dockerImageName: 'my-container-image-name'
59
77
dockerfilePath: 'Dockerfile'
60
- monitorWhen: 'always'
61
78
failOnIssues: true
79
+ monitorWhen: 'always'
62
80
```
63
81
64
82
---
Original file line number Diff line number Diff line change 19
19
20
20
/* Source Map Options */
21
21
"inlineSourceMap" : true /* Emit a single file with source maps instead of having a separate file. */ ,
22
- "inlineSources" : true /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */
22
+ "inlineSources" : true /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ ,
23
+ "useUnknownInCatchVariables" : false
23
24
}
24
25
}
Original file line number Diff line number Diff line change 50
50
"dependencies" : {
51
51
"azure-pipelines-task-lib" : " 2.9.3" ,
52
52
"jquery" : " ^3.4.1" ,
53
- "request" : " ^2.88.0" ,
54
53
"vss-web-extension-sdk" : " ^5.141.0"
55
54
},
56
55
"devDependencies" : {
57
56
"@semantic-release/changelog" : " ^5.0.1" ,
58
57
"@semantic-release/exec" : " ^5.0.0" ,
59
58
"@types/jest" : " ^24.0.18" ,
60
- "@types/node" : " ^12.7.1 " ,
59
+ "@types/node" : " ^16.11.10 " ,
61
60
"@types/q" : " ^1.5.2" ,
62
61
"@typescript-eslint/eslint-plugin" : " ^2.0.0" ,
63
62
"@typescript-eslint/parser" : " ^2.0.0" ,
70
69
"mock-fs" : " ^4.10.4" ,
71
70
"prettier" : " ^2.3.1" ,
72
71
"semantic-release" : " ^17.0.4" ,
73
- "sync-request" : " ^6.1.0" ,
74
72
"tfx-cli" : " ^0.7.11" ,
75
73
"ts-jest" : " ^26.3.0" ,
76
- "typescript" : " ^3 .5.3 "
74
+ "typescript" : " ^4 .5.2 "
77
75
}
78
76
}
Original file line number Diff line number Diff line change 148
148
}
149
149
],
150
150
"execution" : {
151
- "Node " : {
151
+ "Node10 " : {
152
152
"target" : " ./dist/index.js"
153
153
}
154
154
}
Original file line number Diff line number Diff line change 14
14
15
15
/* Source Map Options */
16
16
"inlineSourceMap" : true /* Emit a single file with source maps instead of having a separate file. */ ,
17
- "inlineSources" : true /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */
17
+ "inlineSources" : true /* Emit the source alongside the sourcemaps within a single file; requires '--inlineSourceMap' or '--sourceMap' to be set. */ ,
18
+ "useUnknownInCatchVariables" : false
18
19
}
19
20
}
You can’t perform that action at this time.
0 commit comments