Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update dependencies #64

Merged
merged 6 commits into from
Sep 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2
updates:
- package-ecosystem: gomod
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Install go
uses: actions/setup-go@v3
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: ^1.22
go-version: ^1.23
- name: Check out code into the Go module directory
uses: actions/checkout@v3
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Validate that the release manifest exists
run: |
[[ -f "releases/do-operator-$(git describe --tags).yaml" ]] || false
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Install go
uses: actions/setup-go@v3
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: ^1.22
go-version: ^1.23
- name: Check out code into the Go module directory
uses: actions/checkout@v3
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: Run make test
run: make test
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.22 as builder
FROM golang:1.23 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 @@ -124,8 +124,8 @@ CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen
ENVTEST ?= $(LOCALBIN)/setup-envtest

## Tool Versions
KUSTOMIZE_VERSION ?= v3.8.7
CONTROLLER_TOOLS_VERSION ?= v0.14.0
KUSTOMIZE_VERSION ?= v5.4.3
CONTROLLER_TOOLS_VERSION ?= v0.16.1

KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
.PHONY: kustomize
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.14.0
controller-gen.kubebuilder.io/version: v0.16.1
name: databaseclusterreferences.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.14.0
controller-gen.kubebuilder.io/version: v0.16.1
name: databaseclusters.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.14.0
controller-gen.kubebuilder.io/version: v0.16.1
name: databaseuserreferences.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.14.0
controller-gen.kubebuilder.io/version: v0.16.1
name: databaseusers.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down
88 changes: 6 additions & 82 deletions config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,94 +12,12 @@ rules:
verbs:
- create
- patch
- apiGroups:
- ""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we removing this?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not really removing. This is auto-generated by controller-gen, and, after it's been updated, the new version consolidated rbac permissions into fewer sections. I.e. in the new file https://github.com/digitalocean/do-operator/blob/976400bfda72e67b2174408058342d28b200bffd/config/rbac/role.yaml there's still create and patch on secrets, it's just bundled together with configmaps. Similar with database resources - they're just bundled into a single section with the same verbs

resources:
- secrets
verbs:
- create
- patch
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusterreferences
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusterreferences/finalizers
verbs:
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusterreferences/status
verbs:
- get
- patch
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusters
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusters/finalizers
verbs:
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusters/status
verbs:
- get
- patch
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseuserreferences
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- databases.digitalocean.com
resources:
- databaseuserreferences/finalizers
verbs:
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseuserreferences/status
verbs:
- get
- patch
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseusers
verbs:
- create
Expand All @@ -112,12 +30,18 @@ rules:
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusterreferences/finalizers
- databaseclusters/finalizers
- databaseuserreferences/finalizers
- databaseusers/finalizers
verbs:
- update
- apiGroups:
- databases.digitalocean.com
resources:
- databaseclusterreferences/status
- databaseclusters/status
- databaseuserreferences/status
- databaseusers/status
verbs:
- get
Expand Down
35 changes: 35 additions & 0 deletions fakegodo/databases.go
Original file line number Diff line number Diff line change
Expand Up @@ -408,3 +408,38 @@ func (f *FakeDatabasesService) UpdateMetricsCredentials(ctx context.Context, upd
func (f *FakeDatabasesService) ListDatabaseEvents(ctx context.Context, databaseID string, opts *godo.ListOptions) ([]godo.DatabaseEvent, *godo.Response, error) {
panic("not implemented")
}

// ListIndexes...
func (f *FakeDatabasesService) ListIndexes(context.Context, string, *godo.ListOptions) ([]godo.DatabaseIndex, *godo.Response, error) {
panic("not implemented")
}

// DeleteIndex...
func (f *FakeDatabasesService) DeleteIndex(context.Context, string, string) (*godo.Response, error) {
panic("not implemented")
}

// CreateLogsink...
func (f *FakeDatabasesService) CreateLogsink(context.Context, string, *godo.DatabaseCreateLogsinkRequest) (*godo.DatabaseLogsink, *godo.Response, error) {
panic("not implemented")
}

// GetLogsink...
func (f *FakeDatabasesService) GetLogsink(context.Context, string, string) (*godo.DatabaseLogsink, *godo.Response, error) {
panic("not implemented")
}

// ListLogsinks...
func (f *FakeDatabasesService) ListLogsinks(context.Context, string, *godo.ListOptions) ([]godo.DatabaseLogsink, *godo.Response, error) {
panic("not implemented")
}

// UpdateLogsink...
func (f *FakeDatabasesService) UpdateLogsink(context.Context, string, string, *godo.DatabaseUpdateLogsinkRequest) (*godo.Response, error) {
panic("not implemented")
}

// DeleteLogsink...
func (f *FakeDatabasesService) DeleteLogsink(context.Context, string, string) (*godo.Response, error) {
panic("not implemented")
}
58 changes: 31 additions & 27 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,31 +1,33 @@
module github.com/digitalocean/do-operator

go 1.22.0
go 1.23.0

toolchain go1.22.2
// older version of mergo is required by k8s.io/client-go
replace github.com/imdario/mergo => github.com/imdario/mergo v0.3.6

require (
github.com/digitalocean/godo v1.114.0
github.com/digitalocean/godo v1.121.0
github.com/google/go-cmp v0.6.0
github.com/google/uuid v1.6.0
github.com/onsi/ginkgo v1.16.5
github.com/onsi/gomega v1.33.1
golang.org/x/oauth2 v0.20.0
k8s.io/api v0.30.0
k8s.io/apimachinery v0.30.0
k8s.io/client-go v0.30.0
k8s.io/utils v0.0.0-20240502163921-fe8a2dddb1d0
sigs.k8s.io/controller-runtime v0.18.2
golang.org/x/oauth2 v0.22.0
k8s.io/api v0.31.0
k8s.io/apimachinery v0.31.0
k8s.io/client-go v0.31.0
k8s.io/utils v0.0.0-20240821151609-f90d01438635
sigs.k8s.io/controller-runtime v0.19.0
)

require (
github.com/beorn7/perks v1.0.1 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful/v3 v3.12.0 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/emicklei/go-restful/v3 v3.12.1 // indirect
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/go-logr/logr v1.4.1 // indirect
github.com/fxamacker/cbor/v2 v2.7.0 // indirect
github.com/go-logr/logr v1.4.2 // indirect
github.com/go-logr/zapr v1.3.0 // indirect
github.com/go-openapi/jsonpointer v0.21.0 // indirect
github.com/go-openapi/jsonreference v0.21.0 // indirect
Expand All @@ -37,38 +39,40 @@ require (
github.com/google/go-querystring v1.1.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/hashicorp/go-cleanhttp v0.5.2 // indirect
github.com/hashicorp/go-retryablehttp v0.7.5 // indirect
github.com/imdario/mergo v0.3.16 // indirect
github.com/hashicorp/go-retryablehttp v0.7.7 // indirect
github.com/imdario/mergo v1.0.1 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.17.9 // indirect
github.com/mailru/easyjson v0.7.7 // 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/pkg/errors v0.9.1 // indirect
github.com/prometheus/client_golang v1.19.0 // indirect
github.com/prometheus/client_golang v1.20.2 // indirect
github.com/prometheus/client_model v0.6.1 // indirect
github.com/prometheus/common v0.53.0 // indirect
github.com/prometheus/procfs v0.14.0 // indirect
github.com/prometheus/common v0.57.0 // indirect
github.com/prometheus/procfs v0.15.1 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/x448/float16 v0.8.4 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.27.0 // indirect
golang.org/x/exp v0.0.0-20240506185415-9bf2ced13842 // indirect
golang.org/x/net v0.25.0 // indirect
golang.org/x/sys v0.20.0 // indirect
golang.org/x/term v0.20.0 // indirect
golang.org/x/text v0.15.0 // indirect
golang.org/x/time v0.5.0 // indirect
golang.org/x/exp v0.0.0-20240823005443-9b4947da3948 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/sys v0.24.0 // indirect
golang.org/x/term v0.23.0 // indirect
golang.org/x/text v0.17.0 // indirect
golang.org/x/time v0.6.0 // indirect
gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect
google.golang.org/protobuf v1.34.1 // indirect
google.golang.org/protobuf v1.34.2 // 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.1 // indirect
k8s.io/apiextensions-apiserver v0.30.0 // indirect
k8s.io/klog/v2 v2.120.1 // indirect
k8s.io/kube-openapi v0.0.0-20240430033511-f0e62f92d13f // indirect
k8s.io/apiextensions-apiserver v0.31.0 // indirect
k8s.io/klog/v2 v2.130.1 // indirect
k8s.io/kube-openapi v0.0.0-20240827152857-f7e401e7b4c2 // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.4.0 // indirect
Expand Down
Loading
Loading