From 78b419909bdf1eeb4af17fff471b381de91bcf73 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Fri, 12 Feb 2021 17:59:50 +0100 Subject: Enable more golangci-lint linters Cleanup the golangci.yml file and enable more linters. `pkg/spec` and `iopodman.io` is history. The vendor directory is excluded by default. The dependencies dir was listed twice. Fix the reported problems in `pkg/specgen` because that was also excluded by `pkg/spec`. Enable the structcheck, typecheck, varcheck, deadcode and depguard linters. [NO TESTS NEEDED] Signed-off-by: Paul Holzinger --- pkg/specgen/container_validate.go | 1 - 1 file changed, 1 deletion(-) (limited to 'pkg/specgen/container_validate.go') diff --git a/pkg/specgen/container_validate.go b/pkg/specgen/container_validate.go index 81cb8b78d..042e20e02 100644 --- a/pkg/specgen/container_validate.go +++ b/pkg/specgen/container_validate.go @@ -29,7 +29,6 @@ func exclusiveOptions(opt1, opt2 string) error { // Validate verifies that the given SpecGenerator is valid and satisfies required // input for creating a container. func (s *SpecGenerator) Validate() error { - if rootless.IsRootless() && len(s.CNINetworks) == 0 { if s.StaticIP != nil || s.StaticIPv6 != nil { return ErrNoStaticIPRootless -- cgit v1.2.3-54-g00ecf