forked from cert-manager/cert-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.golangci.ci.yaml
37 lines (37 loc) · 1.65 KB
/
.golangci.ci.yaml
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
# This golangci-lint configuration is for use in CI.
# It has a non-standard filename so that maintainers can still easily run the
# full `golangci-lint` suite locally on their laptops.
# This configuration limits golangci-lint to check only for those issues that
# have already been fixed. to allow us to incrementally fix the remaining
# issues.
# Please contribute small PRs where a new linter is added or a particular
# exclude is removed in the first commit, wait for golangci-lint-action to
# report the issues and then fix those issues in a subsequent commit.
linters:
disable-all: true
enable:
- gosec
- staticcheck
issues:
# When we enable a new linter or a new issue check, we want to show **all**
# instances of each issue in the GitHub UI or in the CLI report. This allows
# the all the issues to be addressed in a single commit or addressed in a
# series of followup commits grouped per-package or per-module.
# By default golangci-lint only shows 50 issues per linter and only shows the
# first three instances of any particular issue. Why? We do not know, but
# perhaps it's to avoid overwhelming the user when there are a large number of
# issues.
# The value 0 below means show all.
max-issues-per-linter: 0
max-same-issues: 0
# Ignore some of the gosec warnings until we have time to address them.
exclude-rules:
- linters:
- gosec
text: "G(101|107|204|306|402)"
- linters:
- staticcheck
text: "SA(1002|1006|4000|4006)"
- linters:
- staticcheck
text: "(NewCertManagerBasicCertificateRequest|DeprecatedCertificateTemplateFromCertificateRequestAndAllowInsecureCSRUsageDefinition)"