Skip to content

Commit

Permalink
Bump golangci-lint + fix lint issues
Browse files Browse the repository at this point in the history
Signed-off-by: Volker Theile <vtheile@suse.com>
  • Loading branch information
votdev authored and ibrokethecloud committed Apr 17, 2024
1 parent f4ef139 commit d154dc3
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Dockerfile.dapper
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ RUN export K8S_VERSION=1.24.2 && \
tar -C /usr/local/kubebuilder --strip-components=1 -zvxf envtest-bins.tar.gz

## install golangci
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.55.2
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.57.1

ENV GO111MODULE on
ENV DAPPER_ENV REPO TAG DRONE_TAG
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func main() {
},
}

app.Action = func(c *cli.Context) error {
app.Action = func(_ *cli.Context) error {
return run(kubeConfig)
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/deviceplugins/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ func gRPCConnect(existingCtx context.Context, socketPath string, timeout time.Du
c, err := grpc.DialContext(ctx, socketPath,
grpc.WithTransportCredentials(insecure.NewCredentials()),
grpc.WithBlock(),
grpc.WithContextDialer(func(ctx context.Context, addr string) (net.Conn, error) {
grpc.WithContextDialer(func(_ context.Context, addr string) (net.Conn, error) {
return net.DialTimeout("unix", addr, timeout)
}),
)
Expand Down
2 changes: 1 addition & 1 deletion pkg/webhook/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func (s *AdmissionWebhookServer) ListenAndServe() error {

func (s *AdmissionWebhookServer) listenAndServe(clients *Clients, handler http.Handler, mutationResources []types.Resource, validationResources []types.Resource) error {
apply := clients.Clients.Apply.WithDynamicLookup()
clients.Clients.Core.Secret().OnChange(s.context, "secrets", func(key string, secret *corev1.Secret) (*corev1.Secret, error) {
clients.Clients.Core.Secret().OnChange(s.context, "secrets", func(_ string, secret *corev1.Secret) (*corev1.Secret, error) {
if secret == nil || secret.Name != caName || secret.Namespace != namespace || len(secret.Data[corev1.TLSCertKey]) == 0 {
return nil, nil
}
Expand Down

0 comments on commit d154dc3

Please sign in to comment.