Skip to content

Commit

Permalink
Update operator-sdk to v1.14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
abdulhaseeb2 committed May 12, 2022
1 parent 560d2b0 commit eab4436
Show file tree
Hide file tree
Showing 10 changed files with 235 additions and 80 deletions.
6 changes: 2 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ BUNDLE_IMG ?= $(IMAGE_TAG_BASE)-bundle:v$(VERSION)

# Image URL to use all building/pushing image targets
IMG ?= stakater/jira-service-desk-operator:v$(VERSION)
# Produce CRDs that work back to Kubernetes 1.11 (no version conversion)
CRD_OPTIONS ?= "crd:trivialVersions=true,crdVersions=v1,preserveUnknownFields=false"

# GOLANGCI_LINT env
GOLANGCI_LINT = _output/tools/golangci-lint
Expand Down Expand Up @@ -79,7 +77,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

generate: controller-gen ## Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
$(CONTROLLER_GEN) object:headerFile="hack/boilerplate.go.txt" paths="./..."
Expand Down Expand Up @@ -143,7 +141,7 @@ TMP_DIR=$$(mktemp -d) ;\
cd $$TMP_DIR ;\
go mod init tmp ;\
echo "Downloading $(2)" ;\
GOBIN=$(PROJECT_DIR)/bin go get $(2) ;\
GOBIN=$(PROJECT_DIR)/bin go install $(2) ;\
rm -rf $$TMP_DIR ;\
}
endef
Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/customer_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func (r *Customer) SetupWebhookWithManager(mgr ctrl.Manager) error {

// EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!

//+kubebuilder:webhook:path=/mutate-jiraservicedesk-stakater-com-v1alpha1-customer,mutating=true,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=customers,verbs=create;update,versions=v1alpha1,name=mcustomer.kb.io,admissionReviewVersions={v1,v1beta1}
//+kubebuilder:webhook:path=/mutate-jiraservicedesk-stakater-com-v1alpha1-customer,mutating=true,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=customers,verbs=create;update,versions=v1alpha1,name=mcustomer.kb.io,admissionReviewVersions=v1

var _ webhook.Defaulter = &Customer{}

Expand All @@ -48,7 +48,7 @@ func (r *Customer) Default() {
}

// TODO(user): change verbs to "verbs=create;update;delete" if you want to enable deletion validation.
//+kubebuilder:webhook:path=/validate-jiraservicedesk-stakater-com-v1alpha1-customer,mutating=false,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=customers,verbs=create;update,versions=v1alpha1,name=vcustomer.kb.io,admissionReviewVersions={v1,v1beta1}
//+kubebuilder:webhook:path=/validate-jiraservicedesk-stakater-com-v1alpha1-customer,mutating=false,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=customers,verbs=create;update,versions=v1alpha1,name=vcustomer.kb.io,admissionReviewVersions=v1

var _ webhook.Validator = &Customer{}

Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/project_webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func (r *Project) SetupWebhookWithManager(mgr ctrl.Manager) error {

// EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!

//+kubebuilder:webhook:path=/mutate-jiraservicedesk-stakater-com-v1alpha1-project,mutating=true,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=projects,verbs=create;update,versions=v1alpha1,name=mproject.kb.io,admissionReviewVersions={v1,v1beta1}
//+kubebuilder:webhook:path=/mutate-jiraservicedesk-stakater-com-v1alpha1-project,mutating=true,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=projects,verbs=create;update,versions=v1alpha1,name=mproject.kb.io,admissionReviewVersions=v1

var _ webhook.Defaulter = &Project{}

Expand All @@ -48,7 +48,7 @@ func (r *Project) Default() {
}

// TODO(user): change verbs to "verbs=create;update;delete" if you want to enable deletion validation.
//+kubebuilder:webhook:path=/validate-jiraservicedesk-stakater-com-v1alpha1-project,mutating=false,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=projects,verbs=create;update,versions=v1alpha1,name=vproject.kb.io,admissionReviewVersions={v1,v1beta1}
//+kubebuilder:webhook:path=/validate-jiraservicedesk-stakater-com-v1alpha1-project,mutating=false,failurePolicy=fail,sideEffects=None,groups=jiraservicedesk.stakater.com,resources=projects,verbs=create;update,versions=v1alpha1,name=vproject.kb.io,admissionReviewVersions=v1

var _ webhook.Validator = &Project{}

Expand Down
1 change: 1 addition & 0 deletions api/v1alpha1/zz_generated.deepcopy.go

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

2 changes: 1 addition & 1 deletion bundle.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ LABEL operators.operatorframework.io.bundle.manifests.v1=manifests/
LABEL operators.operatorframework.io.bundle.metadata.v1=metadata/
LABEL operators.operatorframework.io.bundle.package.v1=jira-service-desk-operator
LABEL operators.operatorframework.io.bundle.channels.v1=alpha
LABEL operators.operatorframework.io.metrics.builder=operator-sdk-v1.11.0+git
LABEL operators.operatorframework.io.metrics.builder=operator-sdk-v1.14.0+git
LABEL operators.operatorframework.io.metrics.mediatype.v1=metrics+v1
LABEL operators.operatorframework.io.metrics.project_layout=go.kubebuilder.io/v3

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ metadata:
}
]
capabilities: Basic Install
operators.operatorframework.io/builder: operator-sdk-v1.11.0+git
operators.operatorframework.io/builder: operator-sdk-v1.14.0+git
operators.operatorframework.io/project_layout: go.kubebuilder.io/v3
name: jira-service-desk-operator.v0.0.47
namespace: placeholder
Expand Down Expand Up @@ -262,7 +262,6 @@ spec:
webhookdefinitions:
- admissionReviewVersions:
- v1
- v1beta1
containerPort: 443
deploymentName: jira-service-desk-operator-controller-manager
failurePolicy: Fail
Expand All @@ -283,7 +282,6 @@ spec:
webhookPath: /validate-jiraservicedesk-stakater-com-v1alpha1-customer
- admissionReviewVersions:
- v1
- v1beta1
containerPort: 443
deploymentName: jira-service-desk-operator-controller-manager
failurePolicy: Fail
Expand All @@ -304,7 +302,6 @@ spec:
webhookPath: /validate-jiraservicedesk-stakater-com-v1alpha1-project
- admissionReviewVersions:
- v1
- v1beta1
containerPort: 443
deploymentName: jira-service-desk-operator-controller-manager
failurePolicy: Fail
Expand All @@ -325,7 +322,6 @@ spec:
webhookPath: /mutate-jiraservicedesk-stakater-com-v1alpha1-customer
- admissionReviewVersions:
- v1
- v1beta1
containerPort: 443
deploymentName: jira-service-desk-operator-controller-manager
failurePolicy: Fail
Expand Down
2 changes: 1 addition & 1 deletion bundle/metadata/annotations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ annotations:
operators.operatorframework.io.bundle.metadata.v1: metadata/
operators.operatorframework.io.bundle.package.v1: jira-service-desk-operator
operators.operatorframework.io.bundle.channels.v1: alpha
operators.operatorframework.io.metrics.builder: operator-sdk-v1.11.0+git
operators.operatorframework.io.metrics.builder: operator-sdk-v1.14.0+git
operators.operatorframework.io.metrics.mediatype.v1: metrics+v1
operators.operatorframework.io.metrics.project_layout: go.kubebuilder.io/v3

Expand Down
4 changes: 0 additions & 4 deletions config/webhook/manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ metadata:
webhooks:
- admissionReviewVersions:
- v1
- v1beta1
clientConfig:
service:
name: webhook-service
Expand All @@ -29,7 +28,6 @@ webhooks:
sideEffects: None
- admissionReviewVersions:
- v1
- v1beta1
clientConfig:
service:
name: webhook-service
Expand Down Expand Up @@ -58,7 +56,6 @@ metadata:
webhooks:
- admissionReviewVersions:
- v1
- v1beta1
clientConfig:
service:
name: webhook-service
Expand All @@ -79,7 +76,6 @@ webhooks:
sideEffects: None
- admissionReviewVersions:
- v1
- v1beta1
clientConfig:
service:
name: webhook-service
Expand Down
17 changes: 7 additions & 10 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,14 @@ module github.com/stakater/jira-service-desk-operator
go 1.16

require (
github.com/go-logr/logr v0.3.0
github.com/kr/text v0.2.0 // indirect
github.com/go-logr/logr v0.4.0
github.com/nbio/st v0.0.0-20140626010706-e9e8d9816f32
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e // indirect
github.com/onsi/ginkgo v1.14.1
github.com/onsi/gomega v1.10.2
github.com/onsi/ginkgo v1.16.4
github.com/onsi/gomega v1.15.0
github.com/stakater/operator-utils v0.1.13
gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f // indirect
gopkg.in/h2non/gock.v1 v1.0.16
k8s.io/api v0.20.2
k8s.io/apimachinery v0.20.2
k8s.io/client-go v0.20.2
sigs.k8s.io/controller-runtime v0.8.3
k8s.io/api v0.22.1
k8s.io/apimachinery v0.22.1
k8s.io/client-go v0.22.1
sigs.k8s.io/controller-runtime v0.10.0
)
Loading

0 comments on commit eab4436

Please sign in to comment.