Skip to content

Commit

Permalink
Update csiaddons to v0.5.0 & point volrep to csiaddons
Browse files Browse the repository at this point in the history
This commit updates csiaddons to v0.5.0 and other deps.
This also points volrep to kubernetes-csi-addons repo now.

Signed-off-by: Rakshith R <[email protected]>
  • Loading branch information
Rakshith-R committed Sep 8, 2022
1 parent 14d43fb commit a79738e
Show file tree
Hide file tree
Showing 15 changed files with 215 additions and 247 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/sanity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on: # yamllint disable-line rule:truthy
branches:
- '*'
env:
GO_VERSION: "1.17"
GO_VERSION: "1.18"
IMAGE_TAG_BASE: "quay.io/ramendr/ramen"
IMAGE_REGISTRY: "quay.io"
IMAGE_REPOSITORY: "ramendr"
Expand Down Expand Up @@ -56,7 +56,7 @@ jobs:
- name: GolangCI Lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.37.1
version: v1.49.0

build-image-and-ensure-clean-branch:
name: Build image and ensure clean branch
Expand Down Expand Up @@ -87,7 +87,7 @@ jobs:
retention-days: 1

- name: Go tidy
run: go mod tidy -compat=1.17
run: go mod tidy

- name: Git branch sanity
run: |
Expand Down
23 changes: 23 additions & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,26 @@ linters:
- goheader # TODO: Introduce back post fixing linter errors
- gci
- interfacer # interfacer linter is archived and deprecated (https://github.com/mvdan/interfacer)
# TODO: fix folloing linter errors.
- typecheck
- gofmt
- gofumpt
- exhaustruct
- tagliatelle
- gomoddirectives
- goimports
- nolintlint
- wrapcheck
- varnamelen
- staticcheck
- nosnakecase
- ireturn
- ifshort
- nilnil
- gomnd
- containedctx
- nonamedreturns
- forcetypeassert
- promlinter
- contextcheck
- errname
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM golang:1.17 as builder
FROM golang:1.18 as builder

WORKDIR /workspace
# Copy the Go Modules manifests
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and
$(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./..."

GOLANGCI_URL := https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh
GOLANGCI_VERSION := 1.37.1
GOLANGCI_VERSION := 1.49.0
GOLANGCI_INSTALLED_VER := $(shell testbin/golangci-lint version --format=short 2>&1)
.PHONY: golangci-bin
golangci-bin: ## Download and install goloanci-lint locally if necessary.
Expand All @@ -124,7 +124,7 @@ endif

.PHONY: lint
lint: golangci-bin ## Run configured golangci-lint and pre-commit.sh linters against the code.
testbin/golangci-lint run ./...
testbin/golangci-lint run ./... --config=./.golangci.yaml
hack/pre-commit.sh

ENVTEST_ASSETS_DIR=$(shell pwd)/testbin
Expand Down
2 changes: 1 addition & 1 deletion controllers/drcluster_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import (
"sigs.k8s.io/controller-runtime/pkg/reconcile"
"sigs.k8s.io/controller-runtime/pkg/source"

csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/api/v1alpha1"
csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/apis/csiaddons/v1alpha1"
"github.com/go-logr/logr"
ramen "github.com/ramendr/ramen/api/v1alpha1"
"github.com/ramendr/ramen/controllers/util"
Expand Down
2 changes: 1 addition & 1 deletion controllers/drcluster_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ package controllers_test
import (
"context"

csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/api/v1alpha1"
csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/apis/csiaddons/v1alpha1"
. "github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
. "github.com/onsi/gomega/gstruct"
Expand Down
2 changes: 1 addition & 1 deletion controllers/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ import (
"sigs.k8s.io/controller-runtime/pkg/manager"

volsyncv1alpha1 "github.com/backube/volsync/api/v1alpha1"
volrep "github.com/csi-addons/volume-replication-operator/api/v1alpha1"
volrep "github.com/csi-addons/kubernetes-csi-addons/apis/replication.storage/v1alpha1"
snapv1 "github.com/kubernetes-csi/external-snapshotter/client/v4/apis/volumesnapshot/v1"
ocmclv1 "github.com/open-cluster-management/api/cluster/v1"
ocmworkv1 "github.com/open-cluster-management/api/work/v1"
Expand Down
2 changes: 1 addition & 1 deletion controllers/util/mcv_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import (
"k8s.io/apimachinery/pkg/types"
"sigs.k8s.io/controller-runtime/pkg/client"

csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/api/v1alpha1"
csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/apis/csiaddons/v1alpha1"
rmn "github.com/ramendr/ramen/api/v1alpha1"
viewv1beta1 "github.com/stolostron/multicloud-operators-foundation/pkg/apis/view/v1beta1"
ctrl "sigs.k8s.io/controller-runtime"
Expand Down
2 changes: 1 addition & 1 deletion controllers/util/mw_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import (
dto "github.com/prometheus/client_model/go"
"sigs.k8s.io/controller-runtime/pkg/metrics"

csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/api/v1alpha1"
csiaddonsv1alpha1 "github.com/csi-addons/kubernetes-csi-addons/apis/csiaddons/v1alpha1"
rmn "github.com/ramendr/ramen/api/v1alpha1"
)

Expand Down
2 changes: 1 addition & 1 deletion controllers/volumereplicationgroup_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import (
"github.com/go-logr/logr"
"golang.org/x/time/rate"

volrep "github.com/csi-addons/volume-replication-operator/api/v1alpha1"
volrep "github.com/csi-addons/kubernetes-csi-addons/apis/replication.storage/v1alpha1"
"github.com/google/uuid"
corev1 "k8s.io/api/core/v1"
storagev1 "k8s.io/api/storage/v1"
Expand Down
4 changes: 2 additions & 2 deletions controllers/vrg_volrep.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ import (
"github.com/aws/aws-sdk-go/aws/awserr"
"github.com/go-logr/logr"

volrep "github.com/csi-addons/volume-replication-operator/api/v1alpha1"
volrepController "github.com/csi-addons/volume-replication-operator/controllers"
volrep "github.com/csi-addons/kubernetes-csi-addons/apis/replication.storage/v1alpha1"
volrepController "github.com/csi-addons/kubernetes-csi-addons/controllers/replication.storage"
corev1 "k8s.io/api/core/v1"
storagev1 "k8s.io/api/storage/v1"
k8serrors "k8s.io/apimachinery/pkg/api/errors"
Expand Down
4 changes: 2 additions & 2 deletions controllers/vrg_volrep_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"strings"
"time"

volrep "github.com/csi-addons/volume-replication-operator/api/v1alpha1"
volrepController "github.com/csi-addons/volume-replication-operator/controllers"
volrep "github.com/csi-addons/kubernetes-csi-addons/apis/replication.storage/v1alpha1"
volrepController "github.com/csi-addons/kubernetes-csi-addons/controllers/replication.storage"
. "github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
ramendrv1alpha1 "github.com/ramendr/ramen/api/v1alpha1"
Expand Down
89 changes: 46 additions & 43 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,101 +1,104 @@
module github.com/ramendr/ramen

go 1.17
go 1.18

require (
github.com/aws/aws-sdk-go v1.38.41
github.com/backube/volsync v0.3.0
github.com/csi-addons/kubernetes-csi-addons v0.3.1-0.20220510101231-848e8b27d395
github.com/csi-addons/volume-replication-operator v0.3.1-0.20220623123415-de6a161ca0ed
github.com/csi-addons/kubernetes-csi-addons v0.5.0
github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32
github.com/go-logr/logr v1.2.3
github.com/google/uuid v1.3.0
github.com/kubernetes-csi/external-snapshotter/client/v4 v4.2.0
github.com/onsi/ginkgo v1.16.5
github.com/onsi/gomega v1.19.0
github.com/onsi/gomega v1.20.1
github.com/open-cluster-management/api v0.0.0-20210527013639-a6845f2ebcb1
github.com/operator-framework/api v0.14.1-0.20220413143725-33310d6154f3
github.com/operator-framework/api v0.15.1-0.20220624132056-decf74800a17
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.12.1
github.com/prometheus/client_golang v1.13.0
github.com/prometheus/client_model v0.2.0
github.com/stolostron/config-policy-controller v0.0.0-20220503151013-2a6d24b0ed07
github.com/stolostron/governance-policy-propagator v0.0.0-20220511204303-f1c56f6da1bf
github.com/stolostron/multicloud-operators-foundation v0.0.0-20220315092956-6dc184852d56
github.com/stolostron/multicloud-operators-placementrule v1.2.4-1-20220311-8eedb3f.0.20220411162042-3de0a2f908f1
go.uber.org/zap v1.21.0
golang.org/x/crypto v0.0.0-20220214200702-86341886e292
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8
k8s.io/api v0.23.6
k8s.io/apimachinery v0.23.6
go.uber.org/zap v1.23.0
golang.org/x/crypto v0.0.0-20220829220503-c86fa9a7ed90
golang.org/x/time v0.0.0-20220722155302-e5dcc9cfc0b9
k8s.io/api v0.25.0
k8s.io/apimachinery v0.25.0
k8s.io/client-go v12.0.0+incompatible
k8s.io/component-base v0.23.5
k8s.io/kube-openapi v0.0.0-20220124234850-424119656bbf
sigs.k8s.io/controller-runtime v0.11.2
k8s.io/component-base v0.25.0
k8s.io/kube-openapi v0.0.0-20220803164354-a70c9af30aea
sigs.k8s.io/controller-runtime v0.12.3
)

require (
cloud.google.com/go v0.99.0 // indirect
github.com/Azure/go-autorest v14.2.0+incompatible // indirect
github.com/Azure/go-autorest/autorest v0.11.24 // indirect
github.com/Azure/go-autorest/autorest/adal v0.9.18 // indirect
github.com/Azure/go-autorest/autorest v0.11.28 // indirect
github.com/Azure/go-autorest/autorest/adal v0.9.21 // indirect
github.com/Azure/go-autorest/autorest/date v0.3.0 // indirect
github.com/Azure/go-autorest/logger v0.2.1 // indirect
github.com/Azure/go-autorest/tracing v0.6.0 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/blang/semver v3.5.1+incompatible // indirect
github.com/blang/semver/v4 v4.0.0 // indirect
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/container-storage-interface/spec v1.6.0 // indirect
github.com/csi-addons/spec v0.1.2-0.20211220115741-32fa508dadbe // indirect
github.com/csi-addons/spec v0.1.2-0.20220829042231-b27a0d84b50b // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/evanphx/json-patch v5.6.0+incompatible // indirect
github.com/fsnotify/fsnotify v1.5.1 // indirect
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/go-logr/zapr v1.2.3 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/jsonreference v0.20.0 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang-jwt/jwt/v4 v4.3.0 // indirect
github.com/golang-jwt/jwt/v4 v4.4.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/google/go-cmp v0.5.7 // indirect
github.com/google/gnostic v0.6.9 // indirect
github.com/google/go-cmp v0.5.8 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/googleapis/gnostic v0.5.5 // indirect
github.com/imdario/mergo v0.3.12 // indirect
github.com/imdario/mergo v0.3.13 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/kubernetes-csi/csi-lib-utils v0.11.0 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/nxadm/tail v1.4.8 // indirect
github.com/prometheus/common v0.32.1 // indirect
github.com/prometheus/procfs v0.7.3 // indirect
github.com/prometheus/common v0.37.0 // indirect
github.com/prometheus/procfs v0.8.0 // indirect
github.com/sirupsen/logrus v1.8.1 // indirect
github.com/spf13/pflag v1.0.5 // indirect
go.uber.org/atomic v1.9.0 // indirect
go.uber.org/multierr v1.7.0 // indirect
golang.org/x/net v0.0.0-20220225172249-27dd8689420f // indirect
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 // indirect
golang.org/x/sys v0.0.0-20220422013727-9388b58f7150 // indirect
golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect
go.uber.org/atomic v1.10.0 // indirect
go.uber.org/multierr v1.8.0 // indirect
golang.org/x/net v0.0.0-20220826154423-83b083e8dc8b // indirect
golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094 // indirect
golang.org/x/sys v0.0.0-20220829200755-d48e67d00261 // indirect
golang.org/x/term v0.0.0-20220722155259-a9ba230a4035 // indirect
golang.org/x/text v0.3.7 // indirect
gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa // indirect
google.golang.org/grpc v1.46.0 // indirect
google.golang.org/protobuf v1.28.0 // indirect
google.golang.org/genproto v0.0.0-20220829175752-36a9c930ecbf // indirect
google.golang.org/grpc v1.49.0 // indirect
google.golang.org/protobuf v1.28.1 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
k8s.io/apiextensions-apiserver v0.23.5 // indirect
k8s.io/klog/v2 v2.60.1 // indirect
k8s.io/utils v0.0.0-20220210201930-3a6ce19ff2f9 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apiextensions-apiserver v0.25.0 // indirect
k8s.io/klog/v2 v2.70.1 // indirect
k8s.io/utils v0.0.0-20220823124924-e9cbc92d1a73 // indirect
open-cluster-management.io/multicloud-operators-subscription v0.6.0 // indirect
sigs.k8s.io/json v0.0.0-20211208200746-9f7c6b3444d2 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.1 // indirect
sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)

replace k8s.io/client-go => k8s.io/client-go v0.23.6
replace k8s.io/client-go => k8s.io/client-go v0.25.0

replace (
github.com/metal3-io/baremetal-operator/apis => github.com/openshift/baremetal-operator/apis v0.0.0-20211201170610-92ffa60c683d
Expand Down
Loading

0 comments on commit a79738e

Please sign in to comment.