forked from erda-project/erda-infra
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.golangci.yml
53 lines (50 loc) · 1.49 KB
/
.golangci.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
run:
concurrency: 4
timeout: 2m
modules-download-mode: mod
# include test files or not, default is true
tests: false
allow-parallel-runners: true
skip-dirs:
- tools
- examples
skip-files:
linters-settings:
goimports:
# local-prefixes: github.com/erda-project/erda-infra
linters:
disable-all: true
# 修复完 issues 后再增加新的 linter
enable:
- goimports
- gosec
- gofmt
issues:
exclude-rules:
- linters:
- gosec
text: "G101:" # G101: Potential hardcoded credentials (gosec)
- linters:
- gosec
text: "G108:" # G108: Profiling endpoint is automatically exposed on /debug/pprof (gosec)
- linters:
- gosec
text: "G109:" # G109: Potential Integer overflow made by strconv.Atoi result conversion to int16/32 (gosec)
- linters:
- gosec
text: "G110:" # G110: Potential DoS vulnerability via decompression bomb (gosec)
- linters:
- gosec
text: "G204:" # G204: Subprocess launched with function call as argument or cmd arguments (gosec)
- linters:
- gosec
text: "G306:" # G306: Expect WriteFile permissions to be 0600 or less
- linters:
- gosec
text: "G402:" # G402: TLS InsecureSkipVerify may be true. (gosec)
- linters:
- gosec
text: "G404:" # G404: Use of weak random number generator (math/rand instead of crypto/rand) (gosec)
- linters:
- gosec
text: "G601:" # G601: Implicit memory aliasing in for loop. (gosec)