Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add SnippetFilter CRD #2472

Merged
2 changes: 2 additions & 0 deletions apis/v1alpha1/register.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ func addKnownTypes(scheme *runtime.Scheme) error {
&ObservabilityPolicyList{},
&ClientSettingsPolicy{},
&ClientSettingsPolicyList{},
&SnippetsFilter{},
&SnippetsFilterList{},
)
// AddToGroupVersion allows the serialization of client types like ListOptions.
metav1.AddToGroupVersion(scheme, SchemeGroupVersion)
Expand Down
16 changes: 9 additions & 7 deletions apis/v1alpha1/snippetsfilter_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,15 @@ type SnippetsFilter struct {
Status SnippetsFilterStatus `json:"status,omitempty"`
}

salonichf5 marked this conversation as resolved.
Show resolved Hide resolved
// +kubebuilder:object:root=true
//
salonichf5 marked this conversation as resolved.
Show resolved Hide resolved
// SnippetsFilterList contains a list of SnippetFilters.
type SnippetsFilterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []SnippetsFilter `json:"items"`
}

// SnippetsFilterSpec defines the desired state of the SnippetsFilter.
type SnippetsFilterSpec struct {
// Snippets is a list of NGINX configuration snippets.
Expand All @@ -41,13 +50,6 @@ type Snippet struct {
Value string `json:"value"`
}

// SnippetsFilterList contains a list of SnippetFilters.
type SnippetsFilterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Snippet `json:"items"`
}

// SnippetsFilterStatus defines the state of SnippetsFilter.
type SnippetsFilterStatus struct {
// Conditions describes the state of the SnippetsFilter.
Expand Down
14 changes: 12 additions & 2 deletions apis/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading