generated from kyma-project/template-repository
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
1,049 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
/* | ||
Copyright 2023. | ||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
http://www.apache.org/licenses/LICENSE-2.0 | ||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
|
||
package v1beta1 | ||
|
||
import ( | ||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" | ||
) | ||
|
||
type SkrStatusCondition struct { | ||
Title string `json:"title"` | ||
ObjKindGroup string `json:"objKindGroup"` | ||
CrdKindGroup string `json:"crdKindGroup"` | ||
BusolaKindGroup string `json:"busolaKindGroup"` | ||
Feature string `json:"feature"` | ||
ObjName string `json:"objName"` | ||
ObjNamespace string `json:"objNamespace"` | ||
Filename string `json:"filename"` | ||
Ok bool `json:"ok"` | ||
Outcomes []string `json:"outcomes"` | ||
} | ||
|
||
// SkrStatusSpec defines the desired state of SkrStatus. | ||
type SkrStatusSpec struct { | ||
KymaName string `json:"kymaName"` | ||
Provider string `json:"provider"` | ||
BrokerPlan string `json:"brokerPlan"` | ||
GlobalAccount string `json:"globalAccount"` | ||
SubAccount string `json:"subAccount"` | ||
Region string `json:"region"` | ||
ShootName string `json:"shootName"` | ||
|
||
PastConnections []metav1.Time `json:"pastConnections,omitempty"` | ||
AverageIntervalSeconds int `json:"averageIntervalSeconds,omitempty"` | ||
|
||
Conditions []SkrStatusCondition `json:"conditions"` | ||
} | ||
|
||
// SkrStatusStatus defines the observed state of SkrStatus. | ||
type SkrStatusStatus struct { | ||
// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster | ||
// Important: Run "make" to regenerate code after modifying this file | ||
} | ||
|
||
// +kubebuilder:object:root=true | ||
// +kubebuilder:subresource:status | ||
|
||
// SkrStatus is the Schema for the skrstatuses API. | ||
type SkrStatus struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ObjectMeta `json:"metadata,omitempty"` | ||
|
||
Spec SkrStatusSpec `json:"spec,omitempty"` | ||
Status SkrStatusStatus `json:"status,omitempty"` | ||
} | ||
|
||
func (in *SkrStatus) CloneForPatch() *SkrStatus { | ||
result := &SkrStatus{ | ||
TypeMeta: in.TypeMeta, | ||
ObjectMeta: metav1.ObjectMeta{ | ||
Namespace: in.Namespace, | ||
Name: in.Name, | ||
}, | ||
Spec: in.Spec, | ||
} | ||
return result | ||
} | ||
|
||
// +kubebuilder:object:root=true | ||
|
||
// SkrStatusList contains a list of SkrStatus. | ||
type SkrStatusList struct { | ||
metav1.TypeMeta `json:",inline"` | ||
metav1.ListMeta `json:"metadata,omitempty"` | ||
Items []SkrStatus `json:"items"` | ||
} | ||
|
||
func init() { | ||
SchemeBuilder.Register(&SkrStatus{}, &SkrStatusList{}) | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
118 changes: 118 additions & 0 deletions
118
config/crd/bases/cloud-control.kyma-project.io_skrstatuses.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,118 @@ | ||
--- | ||
apiVersion: apiextensions.k8s.io/v1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
annotations: | ||
controller-gen.kubebuilder.io/version: v0.16.5 | ||
name: skrstatuses.cloud-control.kyma-project.io | ||
spec: | ||
group: cloud-control.kyma-project.io | ||
names: | ||
kind: SkrStatus | ||
listKind: SkrStatusList | ||
plural: skrstatuses | ||
singular: skrstatus | ||
scope: Namespaced | ||
versions: | ||
- name: v1beta1 | ||
schema: | ||
openAPIV3Schema: | ||
description: SkrStatus is the Schema for the skrstatuses 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 | ||
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 | ||
type: string | ||
metadata: | ||
type: object | ||
spec: | ||
description: SkrStatusSpec defines the desired state of SkrStatus. | ||
properties: | ||
averageIntervalSeconds: | ||
type: integer | ||
brokerPlan: | ||
type: string | ||
conditions: | ||
items: | ||
properties: | ||
busolaKindGroup: | ||
type: string | ||
crdKindGroup: | ||
type: string | ||
feature: | ||
type: string | ||
filename: | ||
type: string | ||
objKindGroup: | ||
type: string | ||
objName: | ||
type: string | ||
objNamespace: | ||
type: string | ||
ok: | ||
type: boolean | ||
outcomes: | ||
items: | ||
type: string | ||
type: array | ||
title: | ||
type: string | ||
required: | ||
- busolaKindGroup | ||
- crdKindGroup | ||
- feature | ||
- filename | ||
- objKindGroup | ||
- objName | ||
- objNamespace | ||
- ok | ||
- outcomes | ||
- title | ||
type: object | ||
type: array | ||
globalAccount: | ||
type: string | ||
kymaName: | ||
type: string | ||
pastConnections: | ||
items: | ||
format: date-time | ||
type: string | ||
type: array | ||
provider: | ||
type: string | ||
region: | ||
type: string | ||
shootName: | ||
type: string | ||
subAccount: | ||
type: string | ||
required: | ||
- brokerPlan | ||
- conditions | ||
- globalAccount | ||
- kymaName | ||
- provider | ||
- region | ||
- shootName | ||
- subAccount | ||
type: object | ||
status: | ||
description: SkrStatusStatus defines the observed state of SkrStatus. | ||
type: object | ||
type: object | ||
served: true | ||
storage: true | ||
subresources: | ||
status: {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.