@@ -22,33 +22,55 @@ import (
22
22
// the projects on OperatorHub.io.
23
23
//
24
24
// This validator will ensure that:
25
+ //
25
26
// - The annotations capabilities into the CSV has a valid option, which are:
26
- // * "Basic Install"
27
- // * "Seamless Upgrades"
28
- // * "Full Lifecycle"
29
- // * "Deep Insights"
30
- // * "Auto Pilot"
27
+ //
28
+ // * Basic Install
29
+ //
30
+ // * Seamless Upgrades
31
+ //
32
+ // * Full Lifecycle
33
+ //
34
+ // * Deep Insights
35
+ //
36
+ // * Auto Pilot
37
+ //
31
38
// - The annotations categories into the CSV has a valid option, which are:
32
- // * "AI/Machine Learning"
33
- // * "Application Runtime"
34
- // * "Big Data"
35
- // * "Cloud Provider"
36
- // * "Developer Tools"
37
- // * "Database"
38
- // * "Integration & Delivery"
39
- // * "Logging & Tracing"
40
- // * "Modernization & Migration"
41
- // * "Monitoring"
42
- // * "Networking"
43
- // * "OpenShift Optional"
44
- // * "Security"
45
- // * "Storage"
46
- // * "Streaming & Messaging"
47
- //
48
- // NOTE: The operatorhub validator can verify against custom bundle categories by setting the OPERATOR_BUNDLE_CATEGORIES
39
+ //
40
+ // * AI/Machine Learning
41
+ //
42
+ // * Application Runtime
43
+ //
44
+ // * Big Data
45
+ //
46
+ // * Cloud Provider
47
+ //
48
+ // * Developer Tools
49
+ //
50
+ // * Database
51
+ //
52
+ // * Integration & Delivery
53
+ //
54
+ // * Logging & Tracing
55
+ //
56
+ // * Modernization & Migration
57
+ //
58
+ // * Monitoring
59
+ //
60
+ // * Networking
61
+ //
62
+ // * OpenShift Optional
63
+ //
64
+ // * Security
65
+ //
66
+ // * Storage
67
+ //
68
+ // * Streaming & Messaging
69
+ //
70
+ // NOTE: The OperatorHub validator can verify against custom bundle categories by setting the OPERATOR_BUNDLE_CATEGORIES
49
71
// environment variable. Setting the OPERATOR_BUNDLE_CATEGORIES environment variable to the path to a json file
50
72
// containing a list of categories will enable those categories to be used when comparing CSV categories for
51
- // operatorhub validation. The json file should be in the following format:
73
+ // OperatorHub validation. The json file should be in the following format:
52
74
//
53
75
// ```json
54
76
// {
@@ -60,24 +82,41 @@ import (
60
82
// }
61
83
// ```
62
84
//
63
- // - The csv.Spec.Provider.Name was provided
64
- // - The csv.Spec.Maintainers elements contains both name and email
65
- // - The csv.Spec.Links elements contains both name and url
66
- // - The csv.Spec.Links.Url is a valid value
67
- // - The csv.Spec.Version is provided
68
- // - The checks.csv.Spec.Icon was provided and has not more than one element
69
- // - The csv.Spec.Icon elements should contain both data and mediatype
70
- // - The csv.Spec.Icon elements should contain both data and mediatype
71
- // - The csv.Spec.Icon has a valid mediatype, which are
72
- // * "image/gif"
73
- // * "image/jpeg"
74
- // * "image/png"
75
- // * "image/svg+xml"
85
+ // - The `csv.Spec.Provider.Name` was provided
86
+ //
87
+ // - The `csv.Spec.Maintainers` elements contains both name and email
88
+ //
89
+ // - The `csv.Spec.Links` elements contains both name and url
90
+ //
91
+ // - The `csv.Spec.Links.Url` is a valid value
92
+ //
93
+ // - The `csv.Spec.Version` is provided
94
+ //
95
+ // - The `csv.Spec.Icon` was provided and has not more than one element
96
+ //
97
+ // - The `csv.Spec.Icon` elements should contain both data and `mediatype`
98
+ //
99
+ // - The `csv.Spec.Icon` elements should contain both data and `mediatype`
100
+ //
101
+ // - The `csv.Spec.Icon` has a valid `mediatype`, which are
102
+ //
103
+ // * image/gif
104
+ //
105
+ // * image/jpeg
106
+ //
107
+ // * image/png
108
+ //
109
+ // * image/svg+xml
110
+ //
76
111
// - If informed ONLY, check if the value csv.Spec.MinKubeVersion is parsable according to semver (https://semver.org/)
77
112
// Also, this validator will raise warnings when:
113
+ //
78
114
// - The bundle name (CSV.metadata.name) does not follow the naming convention: <operator-name>.v<semver> e.g. memcached-operator.v0.0.1
115
+ //
79
116
// NOTE: The bundle name must be 63 characters or less because it will be used as k8s ownerref label which only allows max of 63 characters.
117
+ //
80
118
// - The channel names seems are not following the convention https://olm.operatorframework.io/docs/best-practices/channel-naming/
119
+ //
81
120
// - The usage of the removed APIs on Kubernetes 1.22 is found. More info: https://kubernetes.io/docs/reference/using-api/deprecation-guide/#v1-22
82
121
//
83
122
// Note that this validator allows to receive a List of optional values as key=values. Currently, only the
0 commit comments