Skip to content

Commit

Permalink
update controller-gen and kustomize, update the generated code and ma…
Browse files Browse the repository at this point in the history
…nifests
  • Loading branch information
varshavaradarajan committed Oct 5, 2023
1 parent 1abf73d commit 1bbd36c
Show file tree
Hide file tree
Showing 10 changed files with 15 additions and 18 deletions.
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -124,14 +124,16 @@ CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen
ENVTEST ?= $(LOCALBIN)/setup-envtest

## Tool Versions
KUSTOMIZE_VERSION ?= v3.8.7
CONTROLLER_TOOLS_VERSION ?= v0.9.0
KUSTOMIZE_VERSION ?= v5.0.3
CONTROLLER_TOOLS_VERSION ?= v0.13.0
GOARCH := $(shell go env GOARCH)
GOOS := $(shell go env GOOS)

KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
.PHONY: kustomize
kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary.
$(KUSTOMIZE): $(LOCALBIN)
curl -s $(KUSTOMIZE_INSTALL_SCRIPT) | bash -s -- $(subst v,,$(KUSTOMIZE_VERSION)) $(LOCALBIN)
cd $(LOCALBIN) && curl -fsSL --continue-at - https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2F$(KUSTOMIZE_VERSION)/kustomize_$(KUSTOMIZE_VERSION)_$(GOOS)_$(GOARCH).tar.gz | tar xvz
chmod +x $(KUSTOMIZE)

.PHONY: controller-gen
controller-gen: $(CONTROLLER_GEN) ## Download controller-gen locally if necessary.
Expand Down
2 changes: 1 addition & 1 deletion api/v1alpha1/databasecluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ type DatabaseClusterStatus struct {
//+kubebuilder:subresource:status

// DatabaseCluster is the Schema for the databaseclusters API
//+kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"
// +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"
// +kubebuilder:printcolumn:name="Engine",type=string,JSONPath=`.spec.engine`
// +kubebuilder:printcolumn:name="Cluster name",type=string,JSONPath=`.spec.name`
// +kubebuilder:printcolumn:name="Status",type=string,JSONPath=`.status.status`
Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/groupversion_info.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ limitations under the License.
*/

// Package v1alpha1 contains API Schema definitions for the databases v1alpha1 API group
//+kubebuilder:object:generate=true
//+groupName=databases.digitalocean.com
// +kubebuilder:object:generate=true
// +groupName=databases.digitalocean.com
package v1alpha1

import (
Expand Down
1 change: 0 additions & 1 deletion api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.13.0
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,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.13.0
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,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.13.0
name: databaseuserreferences.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down Expand Up @@ -69,6 +68,7 @@ spec:
- kind
- name
type: object
x-kubernetes-map-type: atomic
username:
description: Username is the username of the referenced user.
type: string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.13.0
name: databaseusers.databases.digitalocean.com
spec:
group: databases.digitalocean.com
Expand Down Expand Up @@ -65,6 +64,7 @@ spec:
- kind
- name
type: object
x-kubernetes-map-type: atomic
username:
description: Username is the username for the user.
type: string
Expand Down
1 change: 0 additions & 1 deletion config/rbac/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
creationTimestamp: null
name: manager-role
rules:
- apiGroups:
Expand Down
1 change: 0 additions & 1 deletion config/webhook/manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
apiVersion: admissionregistration.k8s.io/v1
kind: ValidatingWebhookConfiguration
metadata:
creationTimestamp: null
name: validating-webhook-configuration
webhooks:
- admissionReviewVersions:
Expand Down

0 comments on commit 1bbd36c

Please sign in to comment.