diff --git a/api/v1alpha1/frontend_types.go b/api/v1alpha1/frontend_types.go index 9d1bc902..ac08a38b 100644 --- a/api/v1alpha1/frontend_types.go +++ b/api/v1alpha1/frontend_types.go @@ -39,6 +39,25 @@ type ServiceMonitorConfig struct { Disabled bool `json:"disabled,omitempty"` } +type SearchEntry struct { + ID string `json:"id" yaml:"id"` + Href string `json:"href" yaml:"href"` + Title string `json:"title" yaml:"title"` + Description string `json:"description" yaml:"description"` + AltTitle []string `json:"alt_title" yaml:"alt_title"` + IsExternal bool `json:"isExternal" yaml:"isExternal"` +} + +type ServiceTile struct { + Section string `json:"section" yaml:"section"` + Group string `json:"group" yaml:"group"` + ID string `json:"id" yaml:"id"` + Href string `json:"href" yaml:"href"` + Title string `json:"title" yaml:"title"` + Icon string `json:"icon" yaml:"icon"` + IsExternal bool `json:"isExternal,omitempty" yaml:"isExternal,omitempty"` +} + // FrontendSpec defines the desired state of Frontend type FrontendSpec struct { Disabled bool `json:"disabled,omitempty" yaml:"disabled,omitempty"` @@ -57,6 +76,10 @@ type FrontendSpec struct { AkamaiCacheBustDisable bool `json:"akamaiCacheBustDisable,omitempty" yaml:"akamaiCacheBustDisable,omitempty"` // Files to cache bust AkamaiCacheBustPaths []string `json:"akamaiCacheBustPaths,omitempty" yaml:"akamaiCacheBustPaths,omitempty"` + // The search index partials for the resource + SearchEntries []*SearchEntry `json:"searchEntries,omitempty" yaml:"searchEntries,omitempty"` + // Data for the all services dropdown + ServiceTiles []*ServiceTile `json:"serviceTiles,omitempty" yaml:"serviceTiles,omitempty"` } var ReconciliationSuccessful = "ReconciliationSuccessful" diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 8e4ed9c1..ed9fdaa5 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -543,6 +543,28 @@ func (in *FrontendSpec) DeepCopyInto(out *FrontendSpec) { *out = make([]string, len(*in)) copy(*out, *in) } + if in.SearchEntries != nil { + in, out := &in.SearchEntries, &out.SearchEntries + *out = make([]*SearchEntry, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(SearchEntry) + (*in).DeepCopyInto(*out) + } + } + } + if in.ServiceTiles != nil { + in, out := &in.ServiceTiles, &out.ServiceTiles + *out = make([]*ServiceTile, len(*in)) + for i := range *in { + if (*in)[i] != nil { + in, out := &(*in)[i], &(*out)[i] + *out = new(ServiceTile) + **out = **in + } + } + } } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FrontendSpec. @@ -730,6 +752,26 @@ func (in *Route) DeepCopy() *Route { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *SearchEntry) DeepCopyInto(out *SearchEntry) { + *out = *in + if in.AltTitle != nil { + in, out := &in.AltTitle, &out.AltTitle + *out = make([]string, len(*in)) + copy(*out, *in) + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SearchEntry. +func (in *SearchEntry) DeepCopy() *SearchEntry { + if in == nil { + return nil + } + out := new(SearchEntry) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *ServiceMonitorConfig) DeepCopyInto(out *ServiceMonitorConfig) { *out = *in @@ -745,6 +787,21 @@ func (in *ServiceMonitorConfig) DeepCopy() *ServiceMonitorConfig { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *ServiceTile) DeepCopyInto(out *ServiceTile) { + *out = *in +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ServiceTile. +func (in *ServiceTile) DeepCopy() *ServiceTile { + if in == nil { + return nil + } + out := new(ServiceTile) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *SupportCaseData) DeepCopyInto(out *SupportCaseData) { *out = *in diff --git a/config/crd/bases/cloud.redhat.com_frontends.yaml b/config/crd/bases/cloud.redhat.com_frontends.yaml index 63451c96..aab331c0 100644 --- a/config/crd/bases/cloud.redhat.com_frontends.yaml +++ b/config/crd/bases/cloud.redhat.com_frontends.yaml @@ -304,6 +304,33 @@ spec: - title type: object type: array + searchEntries: + description: The search index partials for the resource + items: + properties: + alt_title: + items: + type: string + type: array + description: + type: string + href: + type: string + id: + type: string + isExternal: + type: boolean + title: + type: string + required: + - alt_title + - description + - href + - id + - isExternal + - title + type: object + type: array service: type: string serviceMonitor: @@ -311,6 +338,33 @@ spec: disabled: type: boolean type: object + serviceTiles: + description: Data for the all services dropdown + items: + properties: + group: + type: string + href: + type: string + icon: + type: string + id: + type: string + isExternal: + type: boolean + section: + type: string + title: + type: string + required: + - group + - href + - icon + - id + - section + - title + type: object + type: array title: type: string required: diff --git a/deploy.yml b/deploy.yml index 9da6cf96..4d5cf697 100644 --- a/deploy.yml +++ b/deploy.yml @@ -751,6 +751,33 @@ objects: - title type: object type: array + searchEntries: + description: The search index partials for the resource + items: + properties: + alt_title: + items: + type: string + type: array + description: + type: string + href: + type: string + id: + type: string + isExternal: + type: boolean + title: + type: string + required: + - alt_title + - description + - href + - id + - isExternal + - title + type: object + type: array service: type: string serviceMonitor: @@ -758,6 +785,33 @@ objects: disabled: type: boolean type: object + serviceTiles: + description: Data for the all services dropdown + items: + properties: + group: + type: string + href: + type: string + icon: + type: string + id: + type: string + isExternal: + type: boolean + section: + type: string + title: + type: string + required: + - group + - href + - icon + - id + - section + - title + type: object + type: array title: type: string required: