Skip to content

Commit 35bd23a

Browse files
committed
Introduce OLMConfig CRD
1 parent f579141 commit 35bd23a

File tree

6 files changed

+375
-0
lines changed

6 files changed

+375
-0
lines changed

crds/defs.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,3 +104,8 @@ func Subscription() *apiextensionsv1.CustomResourceDefinition {
104104
func OperatorCondition() *apiextensionsv1.CustomResourceDefinition {
105105
return getCRD("operators.coreos.com_operatorconditions.yaml").DeepCopy()
106106
}
107+
108+
// OLMConfig returns a copy of the CustomResourceDefinition for the latest version of the OLMConfig API.
109+
func OLMConfig() *apiextensionsv1.CustomResourceDefinition {
110+
return getCRD("operators.coreos.com_olmconfigs.yaml").DeepCopy()
111+
}
Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
apiVersion: apiextensions.k8s.io/v1
2+
kind: CustomResourceDefinition
3+
metadata:
4+
annotations:
5+
controller-gen.kubebuilder.io/version: v0.6.2
6+
creationTimestamp: null
7+
name: olmconfigs.operators.coreos.com
8+
spec:
9+
group: operators.coreos.com
10+
names:
11+
categories:
12+
- olm
13+
kind: OLMConfig
14+
listKind: OLMConfigList
15+
plural: olmconfigs
16+
singular: olmconfig
17+
scope: Cluster
18+
versions:
19+
- name: v1
20+
schema:
21+
openAPIV3Schema:
22+
description: OLMConfig is a resource responsible for configuring OLM.
23+
type: object
24+
required:
25+
- metadata
26+
properties:
27+
apiVersion:
28+
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'
29+
type: string
30+
kind:
31+
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'
32+
type: string
33+
metadata:
34+
type: object
35+
spec:
36+
description: OLMConfigSpec is the spec for an OLMConfig resource.
37+
type: object
38+
properties:
39+
features:
40+
description: Features contains the list of configurable OLM features.
41+
type: object
42+
properties:
43+
disableCopiedCSVs:
44+
description: DisableCopiedCSVs is used to disable OLM's "Copied CSV" feature for operators installed at the cluster scope, where a cluster scoped operator is one that has been installed in an OperatorGroup that targets all namespaces. When reenabled, OLM will recreate the "Copied CSVs" for each cluster scoped operator.
45+
type: boolean
46+
default: false
47+
status:
48+
description: OLMConfigStatus is the status for an OLMConfig resource.
49+
type: object
50+
properties:
51+
conditions:
52+
type: array
53+
items:
54+
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, 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 }"
55+
type: object
56+
required:
57+
- lastTransitionTime
58+
- message
59+
- reason
60+
- status
61+
- type
62+
properties:
63+
lastTransitionTime:
64+
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.
65+
type: string
66+
format: date-time
67+
message:
68+
description: message is a human readable message indicating details about the transition. This may be an empty string.
69+
type: string
70+
maxLength: 32768
71+
observedGeneration:
72+
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.
73+
type: integer
74+
format: int64
75+
minimum: 0
76+
reason:
77+
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.
78+
type: string
79+
maxLength: 1024
80+
minLength: 1
81+
pattern: ^[A-Za-z]([A-Za-z0-9_,:]*[A-Za-z0-9_])?$
82+
status:
83+
description: status of the condition, one of True, False, Unknown.
84+
type: string
85+
enum:
86+
- "True"
87+
- "False"
88+
- Unknown
89+
type:
90+
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)
91+
type: string
92+
maxLength: 316
93+
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])$
94+
served: true
95+
storage: true
96+
subresources:
97+
status: {}

0 commit comments

Comments
 (0)