Closed errordeveloper closed 3 years ago
===== Test: operator-metadata-linting =====
Operator Courier version:
-------------------------
2.1.10 (https://github.com/operator-framework/operator-courier/releases/tag/v2.1.10)
Validation Warnings:
--------------------
"csv metadata.annotations.description not defined"
"csv metadata.annotations.containerImage not defined"
"csv metadata.annotations.createdAt not defined"
"csv metadata.annotations.certified not defined."
"csv metadata.annotations.description not defined.Without this field, the description displayed in the tiles of the UI will be a truncated version of spec.description."
"csv metadata.annotations.createdAt not defined.Without this field, the time stamp at which the operator was created will not be displayed in the UI."
"csv metadata.annotations.containerImage not defined.Without this field, the link to the operator image will not be displayed in the UI."
"csv metadata.annotations.alm-examples not defined.Without this field, users will not have examples of how to write Custom Resources for the operator."
"You should have alm-examples for every owned CRD"
Validation Errors:
------------------
"spec.icon[0].mediatype image/svg is not a valid mediatype. It must be one of \"image/gif\", \"image/jpeg\", \"image/png\", \"image/svg+xml\""
"category Policy Enforcement is not a valid category"
"UI validation failed to verify that required fields for operatorhub.io are properly formatted."
stdout:
-------
stderr:
-------
WARNING: csv metadata.annotations.description not defined [1.9.1/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.containerImage not defined [1.9.1/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.createdAt not defined [1.9.1/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.certified not defined. [1.9.1/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.description not defined.Without this field, the description displayed in the tiles of the UI will be a truncated version of spec.description. [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
WARNING: csv metadata.annotations.createdAt not defined.Without this field, the time stamp at which the operator was created will not be displayed in the UI. [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
WARNING: csv metadata.annotations.containerImage not defined.Without this field, the link to the operator image will not be displayed in the UI. [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
WARNING: csv metadata.annotations.alm-examples not defined.Without this field, users will not have examples of how to write Custom Resources for the operator. [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
WARNING: You should have alm-examples for every owned CRD [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
ERROR: spec.icon[0].mediatype image/svg is not a valid mediatype. It must be one of "image/gif", "image/jpeg", "image/png", "image/svg+xml" [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
ERROR: category Policy Enforcement is not a valid category [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
ERROR: UI validation failed to verify that required fields for operatorhub.io are properly formatted. [ab967328-d17c-4984-a270-cabcb8e31cc0/package.yaml]
Resulting bundle is invalid, input yaml is improperly defined.
return code:
------------
1
-------------------
Execution Reference:
-> /cvp/cvp-isv-operator-metadata-validation-test/certified-ospid-e31ac831-7e72-42bb-baf9-f392ef7ea622-319f5f0d-e5f5-4ff6-b818-d96d67ee2662/ab967328-d17c-4984-a270-cabcb8e31cc0/
Another test that fails is this:
===== Test: operator-metadata-linting-bundle-image =====
Operator SDK version:
-------------------------
operator-sdk version: "v1.3.0", commit: "1abf57985b43bf6a59dcd18147b3c574fa57d3f6", kubernetes version: "1.19.4", go version: "go1.15.5", GOOS: "linux", GOARCH: "amd64"
Validation output:
-------
time="2021-01-19T14:59:09Z" level=debug msg="Debug logging is set"
time="2021-01-19T14:59:09Z" level=fatal msg="[error loading objs in directory: unable to parse CSV cilium-olm.csv.yaml: error unmarshaling JSON: while decoding JSON: json: cannot unmarshal string into Go struct field ClusterServiceVersionSpec.spec.maintainers of type []v1alpha1.Maintainer, no bundle csv found, unable to load bundle from directory ../../../../../test-operator/manifests]"
return code:
------------
1
-------------------
Execution Reference:
-> /cvp/cvp-isv-operator-bundle-image-validation-test/certified-ospid-e31ac831-7e72-42bb-baf9-f392ef7ea622-319f5f0d-e5f5-4ff6-b818-d96d67ee2662/319f5f0d-e5f5-4ff6-b818-d96d67ee2662/
===== Test: operator-metadata-linting =====
Operator Courier version:
-------------------------
2.1.10 (https://github.com/operator-framework/operator-courier/releases/tag/v2.1.10)
Validation Warnings:
--------------------
"csv metadata.annotations.description not defined"
"csv metadata.annotations.containerImage not defined"
"csv metadata.annotations.createdAt not defined"
"csv metadata.annotations.certified not defined."
"csv metadata.annotations.description not defined.Without this field, the description displayed in the tiles of the UI will be a truncated version of spec.description."
"csv metadata.annotations.createdAt not defined.Without this field, the time stamp at which the operator was created will not be displayed in the UI."
"csv metadata.annotations.containerImage not defined.Without this field, the link to the operator image will not be displayed in the UI."
"csv metadata.annotations.alm-examples not defined.Without this field, users will not have examples of how to write Custom Resources for the operator."
"You should have alm-examples for every owned CRD"
Validation Errors:
------------------
"category Policy Enforcement is not a valid category"
"UI validation failed to verify that required fields for operatorhub.io are properly formatted."
stdout:
-------
stderr:
-------
WARNING: csv metadata.annotations.description not defined [1.9.3/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.containerImage not defined [1.9.3/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.createdAt not defined [1.9.3/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.certified not defined. [1.9.3/cilium-olm.csv.yaml]
WARNING: csv metadata.annotations.description not defined.Without this field, the description displayed in the tiles of the UI will be a truncated version of spec.description. [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
WARNING: csv metadata.annotations.createdAt not defined.Without this field, the time stamp at which the operator was created will not be displayed in the UI. [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
WARNING: csv metadata.annotations.containerImage not defined.Without this field, the link to the operator image will not be displayed in the UI. [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
WARNING: csv metadata.annotations.alm-examples not defined.Without this field, users will not have examples of how to write Custom Resources for the operator. [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
WARNING: You should have alm-examples for every owned CRD [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
ERROR: category Policy Enforcement is not a valid category [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
ERROR: UI validation failed to verify that required fields for operatorhub.io are properly formatted. [da060611-8809-4c5b-8cf3-05d8469386b8/package.yaml]
Resulting bundle is invalid, input yaml is improperly defined.
return code:
------------
1
-------------------
Execution Reference:
-> /cvp/cvp-isv-operator-metadata-validation-test/marketplace-ospid-e31ac831-7e72-42bb-baf9-f392ef7ea622-d3aa16f5-4be7-4670-a456-b83128c0ca75/da060611-8809-4c5b-8cf3-05d8469386b8/
Looks like not all categories that UI shows can be used, probably need to use these: https://github.com/operator-framework/api/blob/f8c87b6475392ca7d5f48837fddb398fee92facb/pkg/validation/internal/operatorhub.go#L37-L52