From f59b93c366734c0271a5869010eb6eec888f870b Mon Sep 17 00:00:00 2001 From: Valery Mogilevsky Date: Mon, 23 Sep 2024 15:23:51 +0300 Subject: [PATCH] THREESCALE-11055 APIcast Community release v0.9.0 ~ 3scale 2.15 --- Makefile | 2 +- bundle.Dockerfile | 11 +- ...picast-operator.clusterserviceversion.yaml | 32 +- .../manifests/apps.3scale.net_apicasts.yaml | 275 +++++++++++++----- bundle/metadata/annotations.yaml | 7 +- config/manager/kustomization.yaml | 2 +- config/manager/manager.yaml | 16 +- ...picast-operator.clusterserviceversion.yaml | 2 +- doc/community-release-build.md | 199 +++++++++++++ pkg/apicast/image.go | 2 +- .../deployment_version_test.go | 8 +- 11 files changed, 441 insertions(+), 115 deletions(-) create mode 100644 doc/community-release-build.md diff --git a/Makefile b/Makefile index 6a50e17f..722cc8a5 100644 --- a/Makefile +++ b/Makefile @@ -9,7 +9,7 @@ PROJECT_PATH := $(patsubst %/,%,$(dir $(MKFILE_PATH))) all: manager # Current Operator version -VERSION ?= 0.0.1 +VERSION ?= 0.8.0 # Default bundle image tag BUNDLE_IMG ?= controller-bundle:$(VERSION) # Options for 'bundle-build' diff --git a/bundle.Dockerfile b/bundle.Dockerfile index a6d08f97..f292878f 100644 --- a/bundle.Dockerfile +++ b/bundle.Dockerfile @@ -1,15 +1,20 @@ FROM scratch +# Core bundle labels. LABEL operators.operatorframework.io.bundle.mediatype.v1=registry+v1 LABEL operators.operatorframework.io.bundle.manifests.v1=manifests/ LABEL operators.operatorframework.io.bundle.metadata.v1=metadata/ -LABEL operators.operatorframework.io.bundle.package.v1=apicast-operator -LABEL operators.operatorframework.io.bundle.channels.v1=alpha +LABEL operators.operatorframework.io.bundle.package.v1=apicast-community-operator +LABEL operators.operatorframework.io.bundle.channels.v1=alpha,stable LABEL operators.operatorframework.io.metrics.builder=operator-sdk-v1.2.0 LABEL operators.operatorframework.io.metrics.mediatype.v1=metrics+v1 LABEL operators.operatorframework.io.metrics.project_layout=go.kubebuilder.io/v2 -LABEL operators.operatorframework.io.test.config.v1=tests/scorecard/ + +# Labels for testing. LABEL operators.operatorframework.io.test.mediatype.v1=scorecard+v1 +LABEL operators.operatorframework.io.test.config.v1=tests/scorecard/ + +# Copy files to locations specified by labels. COPY bundle/manifests /manifests/ COPY bundle/metadata /metadata/ COPY bundle/tests/scorecard /tests/scorecard/ diff --git a/bundle/manifests/apicast-operator.clusterserviceversion.yaml b/bundle/manifests/apicast-operator.clusterserviceversion.yaml index e65f6a73..571130ab 100644 --- a/bundle/manifests/apicast-operator.clusterserviceversion.yaml +++ b/bundle/manifests/apicast-operator.clusterserviceversion.yaml @@ -20,22 +20,23 @@ metadata: capabilities: Full Lifecycle categories: Integration & Delivery certified: "false" - containerImage: quay.io/3scale/apicast-operator:master + containerImage: quay.io/vmogilev_rhmi/apicast-operator:v0.8.0 createdAt: "2019-10-27T22:40:00Z" - description: APIcast is an API gateway built on top of NGINX. It is part of the Red Hat 3scale API Management Platform + description: APIcast is an API gateway built on top of NGINX. It is part of the Red Hat 3scale API Management Platform olm.properties: '[{"type": "olm.maxOpenShiftVersion", "value": "4.17"}]' operators.openshift.io/infrastructure-features: '["Disconnected"]' - operators.operatorframework.io/builder: operator-sdk-v1.2.0 + operators.operatorframework.io/builder: operator-sdk-v1.21.0 operators.operatorframework.io/project_layout: go.kubebuilder.io/v2 - repository: https://github.com/3scale/apicast-operator + repository: quay.io/vmogilev_rhmi/apicast-operator support: Red Hat labels: operatorframework.io/arch.amd64: supported operatorframework.io/arch.ppc64le: supported operatorframework.io/arch.s390x: supported - name: apicast-operator.v0.0.1 + name: apicast-community-operator.v0.8.0 namespace: placeholder spec: + #replaces: apicast-community-operator.v0.7.1 apiservicedefinitions: {} customresourcedefinitions: owned: @@ -56,10 +57,10 @@ spec: ### Upgrading your installation The APIcast Operator understands how to run and upgrade between a set of APIcast versions. - See [the upgrade guide](https://github.com/3scale/apicast-operator) for more information. + See [the upgrade guide](https://github.com/3scale/apicast-operator/blob/v0.8.0/doc/operator-user-guide.md#upgrading-APIcast) for more information. ### Documentation - Documentation can be found on our [website](https://github.com/3scale/apicast-operator). + Documentation can be found on our [website](https://github.com/3scale/apicast-operator/tree/v0.8.0). ### Getting help If you encounter any issues while using operator, you can create an issue on our [website](https://github.com/3scale/apicast-operator) for bugs, enhancements, or other requests. @@ -76,7 +77,7 @@ spec: ### License APIcast Operator is licensed under the [Apache 2.0 license](https://github.com/3scale/apicast-operator/blob/master/LICENSE) - displayName: APIcast (development latest) + displayName: APIcast icon: - base64data: PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMTAwcHgiIGhlaWdodD0iNTBweCIgdmlld0JveD0iMCAwIDEwMCA1MCIgdmVyc2lvbj0iMS4xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIj4KICAgIDwhLS0gR2VuZXJhdG9yOiBTa2V0Y2ggNTQuMSAoNzY0OTApIC0gaHR0cHM6Ly9za2V0Y2hhcHAuY29tIC0tPgogICAgPHRpdGxlPkdyb3VwIDI8L3RpdGxlPgogICAgPGRlc2M+Q3JlYXRlZCB3aXRoIFNrZXRjaC48L2Rlc2M+CiAgICA8ZyBpZD0iUGFnZS0xIiBzdHJva2U9Im5vbmUiIHN0cm9rZS13aWR0aD0iMSIgZmlsbD0ibm9uZSIgZmlsbC1ydWxlPSJldmVub2RkIj4KICAgICAgICA8ZyBpZD0iR3JvdXAtMiI+CiAgICAgICAgICAgIDxyZWN0IGlkPSJSZWN0YW5nbGUiIGZpbGw9IiNGRkZGRkYiIHg9IjAiIHk9IjAiIHdpZHRoPSIxMDAiIGhlaWdodD0iNTAiPjwvcmVjdD4KICAgICAgICAgICAgPGcgaWQ9Ikdyb3VwIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxOS45NDY4MDksIDAuMDAwMDAwKSIgZmlsbD0iI0ZGNzMxNCIgZmlsbC1ydWxlPSJub256ZXJvIj4KICAgICAgICAgICAgICAgIDxnIGlkPSJsb2dvLW1hcmsiPgogICAgICAgICAgICAgICAgICAgIDxwYXRoIGQ9Ik0wLDkuMDUyNjMxNjEgQzAsNCA0LjIyMzY5MTg1LDAgOS4zMTM3ODE4MywwIEMxNC41MTIxNzE1LDAgMTguNjI3NTYzOCw0LjEwNTI2MzA2IDE4LjYyNzU2MzgsOS4wNTI2MzE2MSBDMTguNjI3NTYzOCwxNC4xMDUyNjMxIDE0LjQwMzg3MiwxOC4xMDUyNjMxIDkuMzEzNzgxODMsMTguMTA1MjYzMSBDNC4yMjM2OTE4NSwxOC4xMDUyNjMxIDAsMTQuMTA1MjYzMSAwLDkuMDUyNjMxNjEgTTQ4LjYyNjYwNTQsMTEuODk0NzM2OSBDNDguNjI2NjA1NCw4Ljg0MjEwNTMyIDUxLjIyNTgwMDEsNi4zMTU3ODkzNSA1NC4zNjY0OTQyLDYuMzE1Nzg5MzUgQzU3LjUwNzE4OCw2LjMxNTc4OTM1IDYwLjEwNjM4Myw4Ljg0MjEwNTMyIDYwLjEwNjM4MywxMS44OTQ3MzY5IEM2MC4xMDYzODMsMTQuOTQ3MzY4NCA1Ny41MDcxODgsMTcuNDczNjg0NCA1NC4zNjY0OTQyLDE3LjQ3MzY4NDQgQzUxLjExNzUwMDQsMTcuNDczNjg0NCA0OC42MjY2MDU0LDE1LjA1MjYzMTYgNDguNjI2NjA1NCwxMS44OTQ3MzY5IE0zMi45MjMxMzYsMzguMTA1MjYzMSBDMzIuOTIzMTM2LDMxLjU3ODk0NzMgMzguNDQ2NDI1MiwyNi4yMTA1MjYzIDQ1LjE2MTAxMiwyNi4yMTA1MjYzIEM1MS44NzU1OTg5LDI2LjIxMDUyNjMgNTcuMzk4ODg4MiwzMS41Nzg5NDczIDU3LjM5ODg4ODIsMzguMTA1MjYzMSBDNTcuMzk4ODg4Miw0NC42MzE1NzkgNTEuODc1NTk4OSw1MCA0NS4xNjEwMTIsNTAgQzM4LjQ0NjQyNTIsNTAgMzIuOTIzMTM2LDQ0LjczNjg0MTkgMzIuOTIzMTM2LDM4LjEwNTI2MzEiIGlkPSJTaGFwZSI+PC9wYXRoPgogICAgICAgICAgICAgICAgPC9nPgogICAgICAgICAgICA8L2c+CiAgICAgICAgPC9nPgogICAgPC9nPgo8L3N2Zz4= mediatype: image/svg+xml @@ -95,14 +96,7 @@ spec: metadata: labels: app: apicast - com.company: Red_Hat control-plane: controller-manager - rht.comp: 3scale_apicast - rht.comp_ver: "2.15" - rht.prod_name: Red_Hat_Integration - rht.prod_ver: master - rht.subcomp: apicast_operator - rht.subcomp_t: infrastructure spec: containers: - args: @@ -116,8 +110,8 @@ spec: fieldRef: fieldPath: metadata.annotations['olm.targetNamespaces'] - name: RELATED_IMAGE_APICAST - value: quay.io/3scale/apicast:latest - image: quay.io/3scale/apicast-operator:master + value: quay.io/3scale/apicast:v3.15.0 + image: quay.io/vmogilev_rhmi/apicast-operator:v0.8.0 name: manager ports: - containerPort: 8080 @@ -300,7 +294,7 @@ spec: - name: GitHub url: https://github.com/3scale/apicast-operator - name: Documentation - url: https://github.com/3scale/apicast-operator/tree/master + url: https://github.com/3scale/apicast-operator/tree/v0.8.0 maintainers: - email: eastizle+apicastoperator@redhat.com name: Eguzki Astiz @@ -308,4 +302,4 @@ spec: minKubeVersion: 1.19.0 provider: name: Red Hat - version: 0.0.1 + version: 0.8.0 diff --git a/bundle/manifests/apps.3scale.net_apicasts.yaml b/bundle/manifests/apps.3scale.net_apicasts.yaml index 6fc0e163..0fdd38df 100644 --- a/bundle/manifests/apps.3scale.net_apicasts.yaml +++ b/bundle/manifests/apps.3scale.net_apicasts.yaml @@ -22,10 +22,14 @@ spec: description: APIcast is the Schema for the apicasts 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 @@ -38,42 +42,56 @@ spec: description: APIcastSpec defines the desired state of APIcast. properties: adminPortalCredentialsRef: - description: Secret reference to a Kubernetes Secret containing the admin portal endpoint URL. The Secret must be located in the same namespace. + description: Secret reference to a Kubernetes Secret containing the + admin portal endpoint URL. The Secret must be located in the same + namespace. properties: 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 type: object x-kubernetes-map-type: atomic allProxy: - description: AllProxy specifies a HTTP(S) proxy to be used for connecting to services if a protocol-specific proxy is not specified. Authentication is not supported. Format is ://: + description: AllProxy specifies a HTTP(S) proxy to be used for connecting + to services if a protocol-specific proxy is not specified. Authentication + is not supported. Format is ://: type: string cacheConfigurationSeconds: - description: The period (in seconds) that the APIcast configuration will be stored in APIcast's cache. + description: The period (in seconds) that the APIcast configuration + will be stored in APIcast's cache. format: int64 type: integer cacheMaxTime: - description: CacheMaxTime indicates the maximum time to be cached. If cache-control header is not set, the time to be cached will be the defined one. + description: CacheMaxTime indicates the maximum time to be cached. + If cache-control header is not set, the time to be cached will be + the defined one. type: string cacheStatusCodes: - description: CacheStatusCodes defines the status codes for which the response content will be cached. + description: CacheStatusCodes defines the status codes for which the + response content will be cached. type: string configurationLoadMode: - description: ConfigurationLoadMode can be used to set APIcast's configuration load mode. + description: ConfigurationLoadMode can be used to set APIcast's configuration + load mode. enum: - boot - lazy type: string customEnvironments: - description: CustomEnvironments specifies an array of defined custome environments to be loaded + description: CustomEnvironments specifies an array of defined custome + environments to be loaded items: - description: CustomEnvironmentSpec contains or has reference to an APIcast custom environment + description: CustomEnvironmentSpec contains or has reference to + an APIcast custom environment properties: secretRef: - description: LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace. + description: LocalObjectReference contains enough information + to let you locate the referenced object inside the same namespace. properties: 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 type: object x-kubernetes-map-type: atomic @@ -82,18 +100,22 @@ spec: type: object type: array customPolicies: - description: CustomPolicies specifies an array of defined custome policies to be loaded + description: CustomPolicies specifies an array of defined custome + policies to be loaded items: - description: CustomPolicySpec contains or has reference to an APIcast custom policy + description: CustomPolicySpec contains or has reference to an APIcast + custom policy properties: name: description: Name specifies the name of the custom policy type: string secretRef: - description: SecretRef specifies the secret holding the custom policy metadata and lua code + description: SecretRef specifies the secret holding the custom + policy metadata and lua code properties: 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 type: object x-kubernetes-map-type: atomic @@ -107,41 +129,61 @@ spec: type: object type: array deploymentEnvironment: - description: DeploymentEnvironment is the environment for which the configuration will be downloaded from 3scale (Staging or Production), when using APIcast. The value will also be used in the header X-3scale-User-Agent in the authorize/report requests made to 3scale Service Management API. It is used by 3scale for statistics. + description: DeploymentEnvironment is the environment for which the + configuration will be downloaded from 3scale (Staging or Production), + when using APIcast. The value will also be used in the header X-3scale-User-Agent + in the authorize/report requests made to 3scale Service Management + API. It is used by 3scale for statistics. type: string dnsResolverAddress: - description: DNSResolverAddress can be used to specify a custom DNS resolver address to be used by OpenResty. + description: DNSResolverAddress can be used to specify a custom DNS + resolver address to be used by OpenResty. type: string embeddedConfigurationSecretRef: - description: Secret reference to a Kubernetes secret containing the gateway configuration. The Secret must be located in the same namespace. + description: Secret reference to a Kubernetes secret containing the + gateway configuration. The Secret must be located in the same namespace. properties: 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 type: object x-kubernetes-map-type: atomic enabledServices: - description: EnabledServices can be used to specify a list of service IDs used to filter the configured services. + description: EnabledServices can be used to specify a list of service + IDs used to filter the configured services. items: type: string type: array exposedHost: - description: ExposedHost is the domain name used for external access. By default no external access is configured. + description: ExposedHost is the domain name used for external access. + By default no external access is configured. properties: host: type: string tls: items: - description: IngressTLS describes the transport layer security associated with an ingress. + description: IngressTLS describes the transport layer security + associated with an ingress. properties: hosts: - description: hosts is a list of hosts included in the TLS certificate. The values in this list must match the name/s used in the tlsSecret. Defaults to the wildcard host setting for the loadbalancer controller fulfilling this Ingress, if left unspecified. + description: hosts is a list of hosts included in the TLS + certificate. The values in this list must match the name/s + used in the tlsSecret. Defaults to the wildcard host setting + for the loadbalancer controller fulfilling this Ingress, + if left unspecified. items: type: string type: array x-kubernetes-list-type: atomic secretName: - description: secretName is the name of the secret used to terminate TLS traffic on port 443. Field is left optional to allow TLS routing based on SNI hostname alone. If the SNI host in a listener conflicts with the "Host" header field used by an IngressRule, the SNI host is used for termination and value of the "Host" header is used for routing. + description: secretName is the name of the secret used to + terminate TLS traffic on port 443. Field is left optional + to allow TLS routing based on SNI hostname alone. If the + SNI host in a listener conflicts with the "Host" header + field used by an IngressRule, the SNI host is used for + termination and value of the "Host" header is used for + routing. type: string type: object type: array @@ -149,42 +191,57 @@ spec: - host type: object extendedMetrics: - description: ExtendedMetrics enables additional information on Prometheus metrics; some labels will be used with specific information that will provide more in-depth details about APIcast. + description: ExtendedMetrics enables additional information on Prometheus + metrics; some labels will be used with specific information that + will provide more in-depth details about APIcast. type: boolean hpa: description: Enables/disables HPA type: boolean httpProxy: - description: HTTPProxy specifies a HTTP(S) Proxy to be used for connecting to HTTP services. Authentication is not supported. Format is ://: + description: HTTPProxy specifies a HTTP(S) Proxy to be used for connecting + to HTTP services. Authentication is not supported. Format is ://: type: string httpsCertificateSecretRef: - description: HTTPSCertificateSecretRef references secret containing the X.509 certificate in the PEM format and the X.509 certificate secret key. + description: HTTPSCertificateSecretRef references secret containing + the X.509 certificate in the PEM format and the X.509 certificate + secret key. properties: 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 type: object x-kubernetes-map-type: atomic httpsPort: - description: HttpsPort controls on which port APIcast should start listening for HTTPS connections. If this clashes with HTTP port it will be used only for HTTPS. + description: HttpsPort controls on which port APIcast should start + listening for HTTPS connections. If this clashes with HTTP port + it will be used only for HTTPS. format: int32 type: integer httpsProxy: - description: HTTPSProxy specifies a HTTP(S) Proxy to be used for connecting to HTTPS services. Authentication is not supported. Format is ://: + description: HTTPSProxy specifies a HTTP(S) Proxy to be used for connecting + to HTTPS services. Authentication is not supported. Format is ://: type: string httpsVerifyDepth: - description: HTTPSVerifyDepth defines the maximum length of the client certificate chain. + description: HTTPSVerifyDepth defines the maximum length of the client + certificate chain. format: int64 minimum: 0 type: integer image: - description: Image allows overriding the default APIcast gateway container image. This setting should only be used for dev/testing purposes. Setting this disables automated upgrades of the image. + description: Image allows overriding the default APIcast gateway container + image. This setting should only be used for dev/testing purposes. + Setting this disables automated upgrades of the image. type: string loadServicesWhenNeeded: - description: LoadServicesWhenNeeded makes the configurations to be loaded lazily. APIcast will only load the ones configured for the host specified in the host header of the request. + description: LoadServicesWhenNeeded makes the configurations to be + loaded lazily. APIcast will only load the ones configured for the + host specified in the host header of the request. type: boolean logLevel: - description: LogLevel controls the log level of APIcast's OpenResty logs. + description: LogLevel controls the log level of APIcast's OpenResty + logs. enum: - debug - info @@ -196,7 +253,9 @@ spec: - emerg type: string managementAPIScope: - description: ManagementAPIScope controls APIcast Management API scope. The Management API is powerful and can control the APIcast configuration. debug level should only be enabled for debugging purposes. + description: ManagementAPIScope controls APIcast Management API scope. + The Management API is powerful and can control the APIcast configuration. + debug level should only be enabled for debugging purposes. enum: - disabled - status @@ -204,10 +263,14 @@ spec: - debug type: string noProxy: - description: NoProxy specifies a comma-separated list of hostnames and domain names for which the requests should not be proxied. Setting to a single * character, which matches all hosts, effectively disables the proxy. + description: NoProxy specifies a comma-separated list of hostnames + and domain names for which the requests should not be proxied. Setting + to a single * character, which matches all hosts, effectively disables + the proxy. type: string oidcLogLevel: - description: OidcLogLevel allows to set the log level for the logs related to OpenID Connect integration. + description: OidcLogLevel allows to set the log level for the logs + related to OpenID Connect integration. enum: - debug - info @@ -219,61 +282,85 @@ spec: - emerg type: string openSSLPeerVerificationEnabled: - description: OpenSSLPeerVerificationEnabled controls OpenSSL peer verification. + description: OpenSSLPeerVerificationEnabled controls OpenSSL peer + verification. type: boolean openTelemetry: - description: OpenTelemetry contains the gateway instrumentation configuration with APIcast. + description: OpenTelemetry contains the gateway instrumentation configuration + with APIcast. properties: enabled: - description: Enabled controls whether OpenTelemetry integration with APIcast is enabled. By default it is not enabled. + description: Enabled controls whether OpenTelemetry integration + with APIcast is enabled. By default it is not enabled. type: boolean tracingConfigSecretKey: - description: TracingConfigSecretKey contains the key of the secret to select the configuration from. if unspecified, the first secret key in lexicographical order will be selected. + description: TracingConfigSecretKey contains the key of the secret + to select the configuration from. if unspecified, the first + secret key in lexicographical order will be selected. type: string tracingConfigSecretRef: - description: TracingConfigSecretRef contains a Secret reference the Opentelemetry configuration. The configuration file specification is defined in the Nginx instrumentation library repo https://github.com/open-telemetry/opentelemetry-cpp-contrib/tree/main/instrumentation/nginx + description: TracingConfigSecretRef contains a Secret reference + the Opentelemetry configuration. The configuration file specification + is defined in the Nginx instrumentation library repo https://github.com/open-telemetry/opentelemetry-cpp-contrib/tree/main/instrumentation/nginx properties: 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 type: object x-kubernetes-map-type: atomic type: object openTracing: - description: OpenTracingSpec contains the OpenTracing integration configuration with APIcast. Deprecated + description: OpenTracingSpec contains the OpenTracing integration + configuration with APIcast. Deprecated properties: enabled: - description: Enabled controls whether OpenTracing integration with APIcast is enabled. By default it is not enabled. + description: Enabled controls whether OpenTracing integration + with APIcast is enabled. By default it is not enabled. type: boolean tracingConfigSecretRef: - description: TracingConfigSecretRef contains a Secret reference the OpenTracing configuration. Each supported tracing library provides a default configuration file that is used if TracingConfig is not specified. + description: TracingConfigSecretRef contains a Secret reference + the OpenTracing configuration. Each supported tracing library + provides a default configuration file that is used if TracingConfig + is not specified. properties: 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 type: object x-kubernetes-map-type: atomic tracingLibrary: - description: TracingLibrary controls which OpenTracing library is loaded. At the moment the only supported tracer is `jaeger`. If not set, `jaeger` will be used. + description: TracingLibrary controls which OpenTracing library + is loaded. At the moment the only supported tracer is `jaeger`. + If not set, `jaeger` will be used. type: string type: object pathRoutingEnabled: - description: PathRoutingEnabled can be used to enable APIcast's path-based routing in addition to to the default host-based routing. + description: PathRoutingEnabled can be used to enable APIcast's path-based + routing in addition to to the default host-based routing. type: boolean replicas: description: Number of replicas of the APIcast Deployment. format: int64 type: integer resources: - description: Resources can be used to set custom compute Kubernetes Resource Requirements for the APIcast deployment. + description: Resources can be used to set custom compute Kubernetes + Resource Requirements for the APIcast deployment. properties: claims: - description: "Claims lists the names of resources, defined in spec.resourceClaims, that are used by this container. \n This is an alpha field and requires enabling the DynamicResourceAllocation feature gate. \n This field is immutable. It can only be set for containers." + description: "Claims lists the names of resources, defined in + spec.resourceClaims, that are used by this container. \n This + is an alpha field and requires enabling the DynamicResourceAllocation + feature gate. \n This field is immutable. It can only be set + for containers." items: description: ResourceClaim references one entry in PodSpec.ResourceClaims. properties: name: - description: Name must match the name of one entry in pod.spec.resourceClaims of the Pod where this field is used. It makes that resource available inside a container. + description: Name must match the name of one entry in pod.spec.resourceClaims + of the Pod where this field is used. It makes that resource + available inside a container. type: string required: - name @@ -289,7 +376,8 @@ spec: - type: string pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ x-kubernetes-int-or-string: true - description: 'Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/' + description: 'Limits describes the maximum amount of compute resources + allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/' type: object requests: additionalProperties: @@ -298,32 +386,47 @@ spec: - type: string pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ x-kubernetes-int-or-string: true - description: 'Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. Requests cannot exceed Limits. More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/' + description: 'Requests describes the minimum amount of compute + resources required. If Requests is omitted for a container, + it defaults to Limits if that is explicitly specified, otherwise + to an implementation-defined value. Requests cannot exceed Limits. + More info: https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/' type: object type: object responseCodesIncluded: - description: ResponseCodesIncluded can be set to log the response codes of the responses in Apisonator, so they can then be visualized in the 3scale admin portal. + description: ResponseCodesIncluded can be set to log the response + codes of the responses in Apisonator, so they can then be visualized + in the 3scale admin portal. type: boolean serviceAccount: - description: Kubernetes Service Account name to be used for the APIcast Deployment. The Service Account must exist beforehand. + description: Kubernetes Service Account name to be used for the APIcast + Deployment. The Service Account must exist beforehand. type: string serviceCacheSize: - description: ServiceCacheSize specifies the number of services that APICast can store in the internal cache + description: ServiceCacheSize specifies the number of services that + APICast can store in the internal cache format: int32 type: integer serviceConfigurationVersionOverride: additionalProperties: type: string - description: ServiceConfigurationVersionOverride contains service configuration version map to prevent it from auto-updating. + description: ServiceConfigurationVersionOverride contains service + configuration version map to prevent it from auto-updating. type: object servicesFilterByURL: - description: ServicesFilterByURL is used to filter the service configured in the 3scale API Manager, the filter matches with the public base URL (Staging or production). + description: ServicesFilterByURL is used to filter the service configured + in the 3scale API Manager, the filter matches with the public base + URL (Staging or production). type: string timezone: - description: Timezone specifies the local timezone of the APIcast deployment pods. A timezone value available in the TZ database must be set. + description: Timezone specifies the local timezone of the APIcast + deployment pods. A timezone value available in the TZ database must + be set. type: string upstreamRetryCases: - description: UpstreamRetryCases Used only when the retry policy is configured. Specified in which cases a request to the upstream API should be retried. + description: UpstreamRetryCases Used only when the retry policy is + configured. Specified in which cases a request to the upstream API + should be retried. enum: - error - timeout @@ -339,7 +442,8 @@ spec: - "off" type: string workers: - description: Workers defines the number of APIcast's worker processes per pod. + description: Workers defines the number of APIcast's worker processes + per pod. format: int32 minimum: 1 type: integer @@ -348,25 +452,47 @@ spec: description: APIcastStatus defines the observed state of APIcast. properties: conditions: - description: 'Represents the observations of a foo''s current state. Known .status.conditions.type are: "Available"' + description: 'Represents the observations of a foo''s current state. + Known .status.conditions.type are: "Available"' items: - description: "Condition contains details for one aspect of the current state of this API Resource. --- This struct is intended for direct use as an array at the field path .status.conditions. For example, \n type FooStatus struct{ // Represents the observations of a foo's current state. // Known .status.conditions.type are: \"Available\", \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge // +listType=map // +listMapKey=type Conditions []metav1.Condition `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }" + description: "Condition contains details for one aspect of the current + state of this API Resource. --- This struct is intended for direct + use as an array at the field path .status.conditions. For example, + \n type FooStatus struct{ // Represents the observations of a + foo's current state. // Known .status.conditions.type are: \"Available\", + \"Progressing\", and \"Degraded\" // +patchMergeKey=type // +patchStrategy=merge + // +listType=map // +listMapKey=type Conditions []metav1.Condition + `json:\"conditions,omitempty\" patchStrategy:\"merge\" patchMergeKey:\"type\" + protobuf:\"bytes,1,rep,name=conditions\"` \n // other fields }" properties: lastTransitionTime: - description: lastTransitionTime is the last time the condition transitioned from one status to another. This should be when the underlying condition changed. If that is not known, then using the time when the API field changed is acceptable. + description: lastTransitionTime is the last time the condition + transitioned from one status to another. This should be when + the underlying condition changed. If that is not known, then + using the time when the API field changed is acceptable. format: date-time type: string message: - description: message is a human readable message indicating details about the transition. This may be an empty string. + description: message is a human readable message indicating + details about the transition. This may be an empty string. maxLength: 32768 type: string observedGeneration: - description: observedGeneration represents the .metadata.generation that the condition was set based upon. For instance, if .metadata.generation is currently 12, but the .status.conditions[x].observedGeneration is 9, the condition is out of date with respect to the current state of the instance. + description: observedGeneration represents the .metadata.generation + that the condition was set based upon. For instance, if .metadata.generation + is currently 12, but the .status.conditions[x].observedGeneration + is 9, the condition is out of date with respect to the current + state of the instance. format: int64 minimum: 0 type: integer reason: - description: reason contains a programmatic identifier indicating the reason for the condition's last transition. Producers of specific condition types may define expected values and meanings for this field, and whether the values are considered a guaranteed API. The value should be a CamelCase string. This field may not be empty. + description: reason contains a programmatic identifier indicating + the reason for the condition's last transition. Producers + of specific condition types may define expected values and + meanings for this field, and whether the values are considered + a guaranteed API. The value should be a CamelCase string. + This field may not be empty. maxLength: 1024 minLength: 1 pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$ @@ -379,7 +505,11 @@ spec: - Unknown type: string type: - description: type of condition in CamelCase or in foo.example.com/CamelCase. --- Many .condition.type values are consistent across resources like Available, but because arbitrary conditions can be useful (see .node.status.conditions), the ability to deconflict is important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt) + description: type of condition in CamelCase or in foo.example.com/CamelCase. + --- Many .condition.type values are consistent across resources + like Available, but because arbitrary conditions can be useful + (see .node.status.conditions), the ability to deconflict is + important. The regex it matches is (dns1123SubdomainFmt/)?(qualifiedNameFmt) maxLength: 316 pattern: ^([a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*/)?(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])$ type: string @@ -398,7 +528,8 @@ spec: description: The image being used in the APIcast deployment. type: string observedGeneration: - description: ObservedGeneration reflects the generation of the most recently observed spec. + description: ObservedGeneration reflects the generation of the most + recently observed spec. format: int64 type: integer type: object diff --git a/bundle/metadata/annotations.yaml b/bundle/metadata/annotations.yaml index 93eb39e5..e1c10d08 100644 --- a/bundle/metadata/annotations.yaml +++ b/bundle/metadata/annotations.yaml @@ -1,11 +1,10 @@ annotations: - operators.operatorframework.io.bundle.channels.v1: alpha + operators.operatorframework.io.bundle.channel.default.v1: stable + operators.operatorframework.io.bundle.channels.v1: alpha,stable operators.operatorframework.io.bundle.manifests.v1: manifests/ operators.operatorframework.io.bundle.mediatype.v1: registry+v1 operators.operatorframework.io.bundle.metadata.v1: metadata/ - operators.operatorframework.io.bundle.package.v1: apicast-operator + operators.operatorframework.io.bundle.package.v1: apicast-community-operator operators.operatorframework.io.metrics.builder: operator-sdk-v1.2.0 operators.operatorframework.io.metrics.mediatype.v1: metrics+v1 operators.operatorframework.io.metrics.project_layout: go.kubebuilder.io/v2 - operators.operatorframework.io.test.config.v1: tests/scorecard/ - operators.operatorframework.io.test.mediatype.v1: scorecard+v1 diff --git a/config/manager/kustomization.yaml b/config/manager/kustomization.yaml index efd472d1..3b71d3e9 100644 --- a/config/manager/kustomization.yaml +++ b/config/manager/kustomization.yaml @@ -6,4 +6,4 @@ kind: Kustomization images: - name: controller newName: quay.io/3scale/apicast-operator - newTag: master + newTag: v0.8.0 diff --git a/config/manager/manager.yaml b/config/manager/manager.yaml index 97283bad..711a8239 100644 --- a/config/manager/manager.yaml +++ b/config/manager/manager.yaml @@ -21,13 +21,13 @@ spec: metadata: labels: control-plane: controller-manager - com.company: Red_Hat - rht.prod_name: Red_Hat_Integration - rht.prod_ver: master - rht.comp: 3scale_apicast - rht.comp_ver: 2.15 - rht.subcomp: apicast_operator - rht.subcomp_t: infrastructure +# com.company: Red_Hat +# rht.prod_name: Red_Hat_Integration +# rht.prod_ver: master +# rht.comp: 3scale_apicast +# rht.comp_ver: 2.15 +# rht.subcomp: apicast_operator +# rht.subcomp_t: infrastructure spec: serviceAccountName: apicast-operator containers: @@ -50,5 +50,5 @@ spec: fieldRef: fieldPath: metadata.namespace - name: RELATED_IMAGE_APICAST - value: "quay.io/3scale/apicast:latest" + value: "quay.io/3scale/apicast:v3.15.0" terminationGracePeriodSeconds: 10 diff --git a/config/manifests/bases/apicast-operator.clusterserviceversion.yaml b/config/manifests/bases/apicast-operator.clusterserviceversion.yaml index d22338f4..c7352257 100644 --- a/config/manifests/bases/apicast-operator.clusterserviceversion.yaml +++ b/config/manifests/bases/apicast-operator.clusterserviceversion.yaml @@ -19,7 +19,7 @@ metadata: operatorframework.io/arch.amd64: supported operatorframework.io/arch.ppc64le: supported operatorframework.io/arch.s390x: supported - name: apicast-operator.vX.Y.Z + name: apicast-operator.v0.0.0 namespace: placeholder spec: apiservicedefinitions: {} diff --git a/doc/community-release-build.md b/doc/community-release-build.md new file mode 100644 index 00000000..d144643c --- /dev/null +++ b/doc/community-release-build.md @@ -0,0 +1,199 @@ +# APIcast-Operator Community Release + +[Introduction](#introduction) +[Main Steps Briefly](#main-steps-briefly) +[Versioning Strategy](#versioning-strategy) +[Steps to Perform Community Release in apicast-operator repo](#steps-to-perform-community-release-in-3scale-operator-repo) +[Prepare release in community-operators-prod repo](#prepare-release-in-community-operators-prod-repo) +[References](#references) + + +## Introduction +* Community Release is primarily created in parallel with minor or patch Product Releases, but a major community may also be released. + * Community Release is not required for every productized build or every product patch release. +* Community release can be released after downstream release +* Community Release codebase is defined by Tag in the [apicast-operator](https://github.com/3scale/apicast-operator) repository. +Tag format as v\.\. (for example: v0.6.0, v0.7.1) +* Community Release bundles are defined in `redhat-openshift-ecosystem` in [apicast-community-operator repo](https://github.com/redhat-openshift-ecosystem/community-operators-prod/tree/main/operators/apicast-community-operator) . + + +## Main Steps Briefly + +Below are briefly the main steps for prepare Community Release + +### APIcast +* Tagging - Search [APIcast repository](https://github.com/3scale/APIcast) for APIcast version and Tag to be used +in Community APIcast operator. For example: tag: v3.15.0 (release 3.15.0) + + +### APIcast operator + +* Create a community release development branch in **apicast-operator** repo, based on the Product release CommitID, + or, if Product release tag is not yet available, - based on **3scale-2.X-stable** branch. Do development. +* Create PR from community release development branch to a **3scale-2.X-stable** branch (PR example: https://github.com/3scale/apicast-operator/pull/226) + * Do development, Test and Merge PR to `3scale-2.X-stable` branch + * **Note**: Build of the PR will create a release image, like https://quay.io/repository/3scale/apicast-operator?tab=tags&tag=v0.7.1 +* Testing - Following Testing will be done: + * Initial installation from Index image, + * Upgrade from previous release +* Tagging - Apply community release Tag (like v0.8.0) to the latest CommitId on the community release development branch. +* Prepare Community release - create PR in **community-operators-prod** repo (based on manifests from **apicast-operator** repo), +as in [PR example - apicast-community-operator (0.7.1)](https://github.com/redhat-openshift-ecosystem/community-operators-prod/pull/2382) + * **Merge of this PR will publish Release**. +* Do sanity test of the Release after publishing + +## Versioning Strategy +Semantic Versioning scheme will be used for Community releases: MAJOR.MINOR.PATCH. +* MAJOR version: Increments when breaking changes are introduced +* MINOR version: Increments when backward-compatible functionality is added. +* PATCH version: Increments when backward-compatible bug fixes are made. +* APIcast ooperator Community releases Versions examples: 0.6.0, 0.7.1, 0.8.0 +* The Version is used in Community releases Tag name + +```shell +$ git tag |grep -E "0.6|0.7" +v0.6.0 +v0.7.0 +v0.7.1 +``` + +* Tag should be signed. Example of signed tag: +``` + git show v0.7.1 +tag v0.7.1 +Tagger: Eguzki Astiz Lezaun +Date: Tue Mar 14 10:46:34 2023 +0100 + +v0.7.1 +-----BEGIN PGP SIGNATURE----- +xxxxx +xxxxx +-----END PGP SIGNATURE----- + +commit 4f3a2e26fa4e97f28cd0d276dc5d46261354afd4 (tag: v0.7.1, tag: show, tag: 3scale-2.13.2-GA, tag: 3scale-2.13.1-GA) +..... +``` + +## Steps to Perform Community Release in 3scale-operator repo +1. Community Release Development Branch + +* Create a Community release development branch **based on Product Release CommitID** +* Create PR and target it to **3scale-2.X-stable** branch + +``` +$ cd apicast-operator +$ git checkout -b apicast-community-v0.8.0 f76e0a60c8590ce8d463180c1f6d558c56d3d9c2 +``` +Note. Commit ID in this example was found as latest commit id from `git log origin/3scale-2.15-stable` + +2. APIcast Components Images - APIcast +* Community release can use its own APIcast image or use existing build of APIcast. + You can search [APIcast repository](https://github.com/3scale/APIcast) for APIcast version and Tag to be used + in Community APIcast operator. For example: tag: v3.15.0 (release 3.15.0) + + +3. Create PR in apicast-operator upstream for new bundle + * Work to have E2E tests passed in PR + * Merge PR to **3scale-2.X-stable** branch + +4. Testing + + * Testing of `apicast-operator` must be completed before open PR in `community-operators-prod` repo + * Testing must be completed before Tagging + * Testing must be done for `Fresh Install` and `Upgrade` + + +5. Tagging + +- Community Release is defined by Tag. +- Tag will be applied to the Community Release Branch +- Tag will be applied after Testing completion. +- Tag will be signed + +``` +$ cd apicast-operator +$ git tag -s v0.8.0 -m "APIcast operator Community Release v0.8.0 , based on " +$ git push myfork v0.11.0 +``` +**Note**. Signed tags use GPG (GNU Privacy Guard) to create a cryptographic signature (GPG installation/details are not provided in this doc) + +## Prepare release in community-operators-prod repo +See Documentation in [Pull Requests in community operators project](https://github.com/operator-framework/community-operators/blob/master/docs/contributing-via-pr.md) + +**IMPORTANT. All previouse steps, including Testing of apicast-operator (Fresh install and Upgrade) must be completed before opening a PR in the community-operators-prod repo** + +* Fork & Clone community-operators-prod repo if you don't have it yet +* Get latest changes + +``` +$ git clone git@github.com:redhat-openshift-ecosystem/community-operators-prod.git +$ cd community-operators-prod + +Example for myfork: +$ git remote -v +myfork git@github.com:valerymo/community-operators-prod.git (fetch) +myfork git@github.com:valerymo/community-operators-prod.git (push) +origin git@github.com:redhat-openshift-ecosystem/community-operators-prod.git (fetch) +origin git@github.com:redhat-openshift-ecosystem/community-operators-prod.git (push) +``` + +* Create branch in community-operators-prod repo +``` +$ git checkout -b apicast-community-operator-v0.8.0 +``` + +* Create a new release folder (similar to previous release) +``` +community-operators-prod/operators/apicast-community-operator/0.8.0 +``` + +* Copy manifests from apicast-operator Community release to community-operators-prod, as for example From [apicast-operator PR](https://github.com/3scale/apicast-operator/pull/226) To [community-operators-prod/operators/apicast-community-operator/0.8.0](community-operators-prod/operators/apicast-community-operator/0.8.0) + +* Update CSV. These are things that need pay attention: + * apicast-operator containerImage + * apicast image + * CVS version + * CSV replaces + * CSV name + * CSV description + * CSV urls + * Annotations + * * Update metadata/annotations and bundle.Dockerfile + + +* Compare apicast-community-operator bundle with previous version, and with apicast-operator +* Finally you will have update release bundle structure. +* Commit your changes and Create PR + * Do Signed-off - git commit -s … , It’s required for PR test Pipeline + +``` +[community-operators-prod] (apicast-community-operator-v0.8.0)$ git log +commit xxxxxxxxxxxx (HEAD -> apicast-community-operator-v0.8.0) +Author: xxx xxx +Date: xxx +apicast-community-operator release v0.8.0 +Signed-off-by: xxx xxx +``` + +``` +$ git push -u myfork apicast-community-operator-v0.8.0 +To github.com:valerymo/community-operators-prod.git +.... +``` + +**IMPORTANT. Merging of community-operators-prod PR will trigger Release creation/publishing** + +* Check and confirm all questions in PR description +* Merge +* Test of created release in OSD cluster / OperatorHub +________________ + + +## References + +* [Community operators project documentation](https://github.com/operator-framework/community-operators/blob/master/docs/contributing-via-pr.md) +* [Community operators repository](https://github.com/k8s-operatorhub/community-operators) +* [K8S PR example](https://github.com/k8s-operatorhub/community-operators/pull/2472) +* [OCP PR example](https://github.com/redhat-openshift-ecosystem/community-operators-prod/pull/2382) +* *Check for the latest guidelines about what it needs to be done; they change from time to time* + * *Community operator release process moved* [here - operator-release-process](https://github.com/operator-framework/community-operators/blob/master/docs/operator-release-process.md) diff --git a/pkg/apicast/image.go b/pkg/apicast/image.go index 1b1bb9ea..177663da 100644 --- a/pkg/apicast/image.go +++ b/pkg/apicast/image.go @@ -2,7 +2,7 @@ package apicast import "github.com/3scale/apicast-operator/pkg/helper" -const defaultImageVersion = "quay.io/3scale/apicast:latest" +const defaultImageVersion = "quay.io/3scale/apicast:v3.15.0" func GetDefaultImageVersion() string { return helper.GetEnvVar("RELATED_IMAGE_APICAST", defaultImageVersion) diff --git a/test/manifests-version/deployment_version_test.go b/test/manifests-version/deployment_version_test.go index 29982574..3053f1f0 100644 --- a/test/manifests-version/deployment_version_test.go +++ b/test/manifests-version/deployment_version_test.go @@ -8,8 +8,6 @@ import ( "path" "testing" - "github.com/3scale/apicast-operator/version" - appsv1 "k8s.io/api/apps/v1" utilyaml "k8s.io/apimachinery/pkg/util/yaml" ) @@ -55,7 +53,7 @@ func TestDeploymentVersions(t *testing.T) { t.Errorf("Parsed object is not a Deployment object") } - if deployment.Spec.Template.Labels["rht.comp_ver"] != version.ThreescaleRelease { - t.Errorf("rht.comp_ver differ: expected: %s; found: %s", version.ThreescaleRelease, deployment.Spec.Template.Labels["rht.comp_ver"]) - } + //if deployment.Spec.Template.Labels["rht.comp_ver"] != version.ThreescaleRelease { + // t.Errorf("rht.comp_ver differ: expected: %s; found: %s", version.ThreescaleRelease, deployment.Spec.Template.Labels["rht.comp_ver"]) + //} }