Skip to content

Commit 7d121c7

Browse files
cognifloydjoelanford
authored andcommitted
Add field Subscription.Spec.Config.Annotations (openshift#312)
* Add field Subscription.Spec.Config.DeploymentAnnotations * Use deploymentAnnotations over deployment_annotations Co-authored-by: Joe Lanford <[email protected]> * Clarify DeploymentAnnotations doc string and regen files * Rename SubscriptionConfig.DeploymentAnnotations to SubscriptionConfig.Annotations --------- Co-authored-by: Joe Lanford <[email protected]> Upstream-repository: api Upstream-commit: 0eaaa1f89530e27a87afba8bc3de66fe16bc038d
1 parent f814ea9 commit 7d121c7

File tree

10 files changed

+50
-2
lines changed

10 files changed

+50
-2
lines changed

manifests/0000_50_olm_00-subscriptions.crd.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,11 @@ spec:
527527
topologyKey:
528528
description: This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed.
529529
type: string
530+
annotations:
531+
description: Annotations is an unstructured key value map stored with each Deployment, Pod, APIService in the Operator. Typically, annotations may be set by external tools to store and retrieve arbitrary metadata. Use this field to pre-define annotations that OLM should add to each of the Subscription's deployments, pods, and apiservices.
532+
type: object
533+
additionalProperties:
534+
type: string
530535
env:
531536
description: Env is a list of environment variables to set in the container. Cannot be updated.
532537
type: array

microshift-manifests/0000_50_olm_00-subscriptions.crd.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,11 @@ spec:
527527
topologyKey:
528528
description: This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed.
529529
type: string
530+
annotations:
531+
description: Annotations is an unstructured key value map stored with each Deployment, Pod, APIService in the Operator. Typically, annotations may be set by external tools to store and retrieve arbitrary metadata. Use this field to pre-define annotations that OLM should add to each of the Subscription's deployments, pods, and apiservices.
532+
type: object
533+
additionalProperties:
534+
type: string
530535
env:
531536
description: Env is a list of environment variables to set in the container. Cannot be updated.
532537
type: array

staging/api/crds/operators.coreos.com_subscriptions.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,11 @@ spec:
524524
topologyKey:
525525
description: This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. Empty topologyKey is not allowed.
526526
type: string
527+
annotations:
528+
description: Annotations is an unstructured key value map stored with each Deployment, Pod, APIService in the Operator. Typically, annotations may be set by external tools to store and retrieve arbitrary metadata. Use this field to pre-define annotations that OLM should add to each of the Subscription's deployments, pods, and apiservices.
529+
type: object
530+
additionalProperties:
531+
type: string
527532
env:
528533
description: Env is a list of environment variables to set in the container. Cannot be updated.
529534
type: array

staging/api/crds/zz_defs.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

staging/api/pkg/operators/v1alpha1/subscription_types.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,13 @@ type SubscriptionConfig struct {
9090
// Use empty object ({}) to erase original sub-attribute values.
9191
// +optional
9292
Affinity *corev1.Affinity `json:"affinity,omitempty" protobuf:"bytes,18,opt,name=affinity"`
93+
94+
// Annotations is an unstructured key value map stored with each Deployment, Pod, APIService in the Operator.
95+
// Typically, annotations may be set by external tools to store and retrieve arbitrary metadata.
96+
// Use this field to pre-define annotations that OLM should add to each of the Subscription's
97+
// deployments, pods, and apiservices.
98+
// +optional
99+
Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,12,rep,name=annotations"`
93100
}
94101

95102
// SubscriptionConditionType indicates an explicit state condition about a Subscription in "abnormal-true"

staging/api/pkg/operators/v1alpha1/zz_generated.deepcopy.go

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/operator-framework/api/crds/operators.coreos.com_subscriptions.yaml

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/operator-framework/api/crds/zz_defs.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/operator-framework/api/pkg/operators/v1alpha1/subscription_types.go

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/operator-framework/api/pkg/operators/v1alpha1/zz_generated.deepcopy.go

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)