diff --git a/Dockerfile.dapper b/Dockerfile.dapper index 6e78d259c..63e91dbad 100644 --- a/Dockerfile.dapper +++ b/Dockerfile.dapper @@ -1,9 +1,10 @@ -FROM registry.suse.com/bci/golang:1.22 +FROM registry.suse.com/bci/golang:1.23 ARG DAPPER_HOST_ARCH=amd64 ARG http_proxy ARG https_proxy ENV HOST_ARCH=${DAPPER_HOST_ARCH} ARCH=${DAPPER_HOST_ARCH} +ENV GOLANGCI_LINT_VERSION="v1.60.3" RUN zypper -n install gcc ca-certificates git wget curl vim less file nfs-client awk docker && \ rm -rf /var/cache/zypp/* @@ -11,7 +12,7 @@ RUN zypper -n install gcc ca-certificates git wget curl vim less file nfs-client ENV GOLANG_ARCH_amd64=amd64 GOLANG_ARCH_arm64=arm64 GOLANG_ARCH=GOLANG_ARCH_${ARCH} \ GOPATH=/go PATH=/go/bin:/usr/local/go/bin:${PATH} SHELL=/bin/bash -RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.55.2 +RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin ${GOLANGCI_LINT_VERSION} ENV DAPPER_SOURCE /go/src/github.com/longhorn/backupstore ENV DAPPER_OUTPUT ./bin coverage.out diff --git a/cmd/list.go b/cmd/list.go index 92edeb654..a88366277 100644 --- a/cmd/list.go +++ b/cmd/list.go @@ -80,7 +80,7 @@ func ResponseLogAndError(v interface{}) { e, isErr := v.(error) _, isRuntimeErr := e.(runtime.Error) if isErr && !isRuntimeErr { - logrus.Errorf(fmt.Sprint(e)) + logrus.Errorf("%v", e) fmt.Println(fmt.Sprint(e)) } else { logrus.Errorf("Caught FATAL error: %s", v) diff --git a/s3/s3_service.go b/s3/s3_service.go index e5aa7366b..761d4e272 100644 --- a/s3/s3_service.go +++ b/s3/s3_service.go @@ -91,7 +91,7 @@ func parseAwsError(err error) error { if reqErr, ok := err.(awserr.RequestFailure); ok { message += fmt.Sprintln(reqErr.StatusCode(), reqErr.RequestID()) } - return fmt.Errorf(message) + return fmt.Errorf("%s", message) } return err }