Skip to content

Commit

Permalink
Upgrade to controller-gen v0.14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
SaaldjorMike committed Apr 8, 2024
1 parent 2aeba22 commit e8d51f9
Show file tree
Hide file tree
Showing 19 changed files with 12,584 additions and 12,991 deletions.
6 changes: 2 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@

# Image URL to use all building/pushing image targets
IMG ?= humio/humio-operator:latest
# Produce CRDs that work back to Kubernetes 1.11 (no version conversion)
CRD_OPTIONS ?= "crd:trivialVersions=true,preserveUnknownFields=false"

# Get the currently used golang install path (in GOPATH/bin, unless GOBIN is set)
ifeq (,$(shell go env GOBIN))
Expand Down Expand Up @@ -38,7 +36,7 @@ help: ## Display this help.
##@ Development

manifests: controller-gen ## Generate WebhookConfiguration, ClusterRole and CustomResourceDefinition objects.
$(CONTROLLER_GEN) $(CRD_OPTIONS) rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases
$(CONTROLLER_GEN) rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
hack/gen-crds.sh # NOTE: This line was custom added for the humio-operator project.

generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
Expand Down Expand Up @@ -91,7 +89,7 @@ undeploy: ## Undeploy controller from the K8s cluster specified in ~/.kube/confi

CONTROLLER_GEN = $(shell pwd)/bin/controller-gen
controller-gen: ## Download controller-gen locally if necessary.
$(call go-install-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.6.2)
$(call go-install-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/controller-gen@v0.14.0)

KUSTOMIZE = $(shell pwd)/bin/kustomize
kustomize: ## Download kustomize locally if necessary.
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.

61 changes: 34 additions & 27 deletions charts/humio-operator/crds/core.humio.com_humioactions.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@

---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.6.2
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.14.0
name: humioactions.core.humio.com
labels:
app: 'humio-operator'
Expand All @@ -28,14 +26,19 @@ spec:
description: HumioAction is the Schema for the humioactions API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
description: |-
APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
description: |-
Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string
metadata:
type: object
Expand All @@ -58,9 +61,9 @@ spec:
type: boolean
type: object
externalClusterName:
description: ExternalClusterName refers to an object of type HumioExternalCluster
where the Humio resources should be created. This conflicts with
ManagedClusterName.
description: |-
ExternalClusterName refers to an object of type HumioExternalCluster where the Humio resources should be created.
This conflicts with ManagedClusterName.
type: string
humioRepositoryProperties:
description: HumioRepositoryProperties indicates this is a Humio Repository
Expand All @@ -78,8 +81,10 @@ spec:
be a valid secret key.
type: string
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?'
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
optional:
description: Specify whether the Secret or its key must
Expand All @@ -88,12 +93,14 @@ spec:
required:
- key
type: object
x-kubernetes-map-type: atomic
type: object
type: object
managedClusterName:
description: ManagedClusterName refers to an object of type HumioCluster
that is managed by the operator where the Humio resources should
be created. This conflicts with ExternalClusterName.
description: |-
ManagedClusterName refers to an object of type HumioCluster that is managed by the operator where the Humio
resources should be created.
This conflicts with ExternalClusterName.
type: string
name:
description: Name is the name of the Action
Expand All @@ -116,8 +123,10 @@ spec:
be a valid secret key.
type: string
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?'
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
optional:
description: Specify whether the Secret or its key must
Expand All @@ -126,6 +135,7 @@ spec:
required:
- key
type: object
x-kubernetes-map-type: atomic
type: object
useProxy:
type: boolean
Expand Down Expand Up @@ -157,8 +167,10 @@ spec:
be a valid secret key.
type: string
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?'
description: |-
Name of the referent.
More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
TODO: Add other useful fields. apiVersion, kind, uid?
type: string
optional:
description: Specify whether the Secret or its key must
Expand All @@ -167,6 +179,7 @@ spec:
required:
- key
type: object
x-kubernetes-map-type: atomic
type: object
channels:
items:
Expand Down Expand Up @@ -242,9 +255,3 @@ spec:
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
50 changes: 25 additions & 25 deletions charts/humio-operator/crds/core.humio.com_humioalerts.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@

---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.6.2
creationTimestamp: null
controller-gen.kubebuilder.io/version: v0.14.0
name: humioalerts.core.humio.com
labels:
app: 'humio-operator'
Expand All @@ -28,14 +26,19 @@ spec:
description: HumioAlert is the Schema for the humioalerts API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
description: |-
APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
description: |-
Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string
metadata:
type: object
Expand All @@ -52,19 +55,20 @@ spec:
description: Description is the description of the Alert
type: string
externalClusterName:
description: ExternalClusterName refers to an object of type HumioExternalCluster
where the Humio resources should be created. This conflicts with
ManagedClusterName.
description: |-
ExternalClusterName refers to an object of type HumioExternalCluster where the Humio resources should be created.
This conflicts with ManagedClusterName.
type: string
labels:
description: Labels are a set of labels on the Alert
items:
type: string
type: array
managedClusterName:
description: ManagedClusterName refers to an object of type HumioCluster
that is managed by the operator where the Humio resources should
be created. This conflicts with ExternalClusterName.
description: |-
ManagedClusterName refers to an object of type HumioCluster that is managed by the operator where the Humio
resources should be created.
This conflicts with ExternalClusterName.
type: string
name:
description: Name is the name of the alert inside Humio
Expand All @@ -73,12 +77,14 @@ spec:
description: Query defines the desired state of the Humio query
properties:
end:
description: 'End is the end time for the query. Defaults to "now"
Deprecated: Will be ignored. All alerts end at "now".'
description: |-
End is the end time for the query. Defaults to "now"
Deprecated: Will be ignored. All alerts end at "now".
type: string
isLive:
description: 'IsLive sets whether the query is a live query. Defaults
to "true" Deprecated: Will be ignored. All alerts are live.'
description: |-
IsLive sets whether the query is a live query. Defaults to "true"
Deprecated: Will be ignored. All alerts are live.
type: boolean
queryString:
description: QueryString is the Humio query that will trigger
Expand Down Expand Up @@ -123,9 +129,3 @@ spec:
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
Loading

0 comments on commit e8d51f9

Please sign in to comment.