-
Notifications
You must be signed in to change notification settings - Fork 26
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
1 parent
fdc02ce
commit 17ae3e9
Showing
13 changed files
with
1,003 additions
and
191 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
package config | ||
|
||
import ( | ||
flowslatest "github.com/netobserv/network-observability-operator/api/v1beta2" | ||
) | ||
|
||
type ServerConfig struct { | ||
Port int `yaml:"port,omitempty" json:"port,omitempty"` | ||
MetricsPort int `yaml:"metricsPort,omitempty" json:"metricsPort,omitempty"` | ||
CertPath string `yaml:"certPath,omitempty" json:"certPath,omitempty"` | ||
KeyPath string `yaml:"keyPath,omitempty" json:"keyPath,omitempty"` | ||
CORSOrigin string `yaml:"corsOrigin,omitempty" json:"corsOrigin,omitempty"` | ||
CORSMethods string `yaml:"corsMethods,omitempty" json:"corsMethods,omitempty"` | ||
CORSHeaders string `yaml:"corsHeaders,omitempty" json:"corsHeaders,omitempty"` | ||
CORSMaxAge string `yaml:"corsMaxAge,omitempty" json:"corsMaxAge,omitempty"` | ||
} | ||
|
||
type LokiConfig struct { | ||
URL string `yaml:"url" json:"url"` | ||
Labels []string `yaml:"labels" json:"labels"` | ||
|
||
StatusURL string `yaml:"statusUrl,omitempty" json:"statusUrl,omitempty"` | ||
Timeout string `yaml:"timeout,omitempty" json:"timeout,omitempty"` | ||
TenantID string `yaml:"tenantID,omitempty" json:"tenantID,omitempty"` | ||
TokenPath string `yaml:"tokenPath,omitempty" json:"tokenPath,omitempty"` | ||
SkipTLS bool `yaml:"skipTls,omitempty" json:"skipTls,omitempty"` | ||
CAPath string `yaml:"caPath,omitempty" json:"caPath,omitempty"` | ||
StatusSkipTLS bool `yaml:"statusSkipTls,omitempty" json:"statusSkipTls,omitempty"` | ||
StatusCAPath string `yaml:"statusCaPath,omitempty" json:"statusCaPath,omitempty"` | ||
StatusUserCertPath string `yaml:"statusUserCertPath,omitempty" json:"statusUserCertPath,omitempty"` | ||
StatusUserKeyPath string `yaml:"statusUserKeyPath,omitempty" json:"statusUserKeyPath,omitempty"` | ||
UseMocks bool `yaml:"useMocks,omitempty" json:"useMocks,omitempty"` | ||
ForwardUserToken bool `yaml:"forwardUserToken,omitempty" json:"forwardUserToken,omitempty"` | ||
AuthCheck string `yaml:"authCheck,omitempty" json:"authCheck,omitempty"` | ||
} | ||
|
||
type ColumnConfig struct { | ||
ID string `yaml:"id" json:"id"` | ||
Name string `yaml:"name" json:"name"` | ||
|
||
Group string `yaml:"group,omitempty" json:"group,omitempty"` | ||
Field string `yaml:"field,omitempty" json:"field,omitempty"` | ||
Calculated string `yaml:"calculated,omitempty" json:"calculated,omitempty"` | ||
Tooltip string `yaml:"tooltip,omitempty" json:"tooltip,omitempty"` | ||
DocURL string `yaml:"docURL,omitempty" json:"docURL,omitempty"` | ||
Filter string `yaml:"filter,omitempty" json:"filter,omitempty"` | ||
Default bool `yaml:"default,omitempty" json:"default,omitempty"` | ||
Width int `yaml:"width,omitempty" json:"width,omitempty"` | ||
} | ||
|
||
type FilterConfig struct { | ||
ID string `yaml:"id" json:"id"` | ||
Name string `yaml:"name" json:"name"` | ||
Component string `yaml:"component" json:"component"` | ||
|
||
Category string `yaml:"category,omitempty" json:"category,omitempty"` | ||
AutoCompleteAddsQuotes bool `yaml:"autoCompleteAddsQuotes,omitempty" json:"autoCompleteAddsQuotes,omitempty"` | ||
Hint string `yaml:"hint,omitempty" json:"hint,omitempty"` | ||
Examples string `yaml:"examples,omitempty" json:"examples,omitempty"` | ||
DocURL string `yaml:"docUrl,omitempty" json:"docUrl,omitempty"` | ||
Placeholder string `yaml:"placeholder,omitempty" json:"placeholder,omitempty"` | ||
} | ||
|
||
type FrontendConfig struct { | ||
RecordTypes []string `yaml:"recordTypes" json:"recordTypes"` | ||
Columns []ColumnConfig `yaml:"columns" json:"columns"` | ||
Sampling int `yaml:"sampling" json:"sampling"` | ||
Features []string `yaml:"features" json:"features"` | ||
|
||
PortNaming flowslatest.ConsolePluginPortConfig `yaml:"portNaming,omitempty" json:"portNaming,omitempty"` | ||
Filters []FilterConfig `yaml:"filters,omitempty" json:"filters,omitempty"` | ||
QuickFilters []flowslatest.QuickFilter `yaml:"quickFilters,omitempty" json:"quickFilters,omitempty"` | ||
AlertNamespaces []string `yaml:"alertNamespaces,omitempty" json:"alertNamespaces,omitempty"` | ||
} | ||
|
||
type PluginConfig struct { | ||
Server ServerConfig `yaml:"server" json:"server"` | ||
Loki LokiConfig `yaml:"loki" json:"loki"` | ||
Frontend FrontendConfig `yaml:"frontend" json:"frontend"` | ||
} |
Oops, something went wrong.