Merge pull request #677 from bart0sh/PR110-publish-on-operatorhub

Updates made during the latest operator publishing
This commit is contained in:
Mikko Ylinen 2021-08-19 20:13:44 +03:00 committed by GitHub
commit 3a2e10dd63
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 19 additions and 6 deletions

View File

@ -198,6 +198,10 @@ There are few useful steps when working with changes to Device Plugins CRDs and
## How to publish a new version of the Intel Device Plugins operator to operatorhub.io ## How to publish a new version of the Intel Device Plugins operator to operatorhub.io
Update metadata.annotations.containerImage and metadata.annotations.createdAT fields in the base CSV manifest file
deployments/operator/manifests/bases/intel-device-plugins-operator.clusterserviceversion.yaml
to match current operator version and current date
Generate package manifests with: Generate package manifests with:
``` ```
$ make packagemanifests OPERATOR_VERSION=0.X.Y $ make packagemanifests OPERATOR_VERSION=0.X.Y
@ -219,14 +223,18 @@ $ operator-sdk olm uninstall
Review the package manifests by uploading the generated `packagemanifests` folder to Review the package manifests by uploading the generated `packagemanifests` folder to
https://operatorhub.io -> Contribute -> Package Your Operator. https://operatorhub.io -> Contribute -> Package Your Operator.
Clone the [Community Operators](https://github.com/operator-framework/community-operators) repo: Clone the [Community Operators](https://github.com/k8s-operatorhub/community-operators) repo:
``` ```
$ git clone https://github.com/operator-framework/community-operators $ git clone https://github.com/k8s-operatorhub/community-operators
``` ```
Copy the generated files to the Community Operators repo: Copy the generated files to the Community Operators repo:
``` ```
$ cp -r packagemanifests/* community-operators/upstream-community-operators/intel-device-plugins/ $ cp -r packagemanifests/* community-operators/operators/intel-device-plugins/
``` ```
Finally, submit a PR. Submit a PR
Check operator page
https://operatorhub.io/operator/intel-device-plugins-operator
after PR is merged

View File

@ -13,7 +13,9 @@ BUILDER ?= "docker"
EXTRA_BUILD_ARGS ?= "" EXTRA_BUILD_ARGS ?= ""
# Current Operator version # Current Operator version
OPERATOR_VERSION ?= 0.19.0 OPERATOR_VERSION ?= 0.21.0
# Previous Operator version
OPERATOR_PREVIOUS_VERSION ?= 0.20.0
# Default bundle image tag # Default bundle image tag
BUNDLE_IMG ?= intel-device-plugins-controller-bundle:$(OPERATOR_VERSION) BUNDLE_IMG ?= intel-device-plugins-controller-bundle:$(OPERATOR_VERSION)
# Options for 'bundle-build' # Options for 'bundle-build'
@ -110,7 +112,7 @@ bundle:
.PHONY: packagemanifests .PHONY: packagemanifests
packagemanifests: packagemanifests:
$(OPERATOR_SDK) generate kustomize manifests -q --input-dir $(OLM_MANIFESTS) --output-dir $(OLM_MANIFESTS) --apis-dir pkg/apis $(OPERATOR_SDK) generate kustomize manifests -q --input-dir $(OLM_MANIFESTS) --output-dir $(OLM_MANIFESTS) --apis-dir pkg/apis
$(KUSTOMIZE) build $(OLM_MANIFESTS) | sed "s|intel-deviceplugin-operator:devel|intel-deviceplugin-operator:$(OPERATOR_VERSION)|" | $(OPERATOR_SDK) generate packagemanifests -q --kustomize-dir $(OLM_MANIFESTS) --version $(OPERATOR_VERSION) $(BUNDLE_METADATA_OPTS) $(KUSTOMIZE) build $(OLM_MANIFESTS) | sed "s|intel-deviceplugin-operator:devel|intel-deviceplugin-operator:$(OPERATOR_VERSION)|" | $(OPERATOR_SDK) generate packagemanifests -q --kustomize-dir $(OLM_MANIFESTS) --version $(OPERATOR_VERSION) --from-version $(OPERATOR_PREVIOUS_VERSION) $(BUNDLE_METADATA_OPTS)
# Remove unneeded resources # Remove unneeded resources
rm packagemanifests/$(OPERATOR_VERSION)/*service.yaml rm packagemanifests/$(OPERATOR_VERSION)/*service.yaml
rm packagemanifests/$(OPERATOR_VERSION)/*clusterrole.yaml rm packagemanifests/$(OPERATOR_VERSION)/*clusterrole.yaml

View File

@ -5,9 +5,12 @@ metadata:
alm-examples: '[]' alm-examples: '[]'
capabilities: Basic Install capabilities: Basic Install
categories: Drivers and plugins categories: Drivers and plugins
containerImage: intel/intel-deviceplugin-operator:0.21.0
createdAt: "2021-08-18"
description: This One Operator is a Kubernetes custom controller whose goal is to serve the installation and lifecycle management of Intel device plugins for Kubernetes. description: This One Operator is a Kubernetes custom controller whose goal is to serve the installation and lifecycle management of Intel device plugins for Kubernetes.
operators.operatorframework.io/builder: operator-sdk-v1.2.0 operators.operatorframework.io/builder: operator-sdk-v1.2.0
operators.operatorframework.io/project_layout: go.kubebuilder.io/v2 operators.operatorframework.io/project_layout: go.kubebuilder.io/v2
repository: https://github.com/intel/intel-device-plugins-for-kubernetes
name: intel-device-plugins-operator.v0.0.0 name: intel-device-plugins-operator.v0.0.0
namespace: placeholder namespace: placeholder
spec: spec: