Documentation
¶
Index ¶
- func DashboardSpec(spec dashboard.Spec, sch schema.Schema, proxyCfg *config.HTTPProxyConfig) error
- func DashboardSpecWithVars(spec dashboard.Spec, sch schema.Schema, proxyCfg *config.HTTPProxyConfig, ...) error
- func DashboardWithCustomRules(dash *modelV1.Dashboard, customRules []*config.CustomLintRule) error
- func Datasource[T modelV1.DatasourceInterface](entity T, list []T, sch schema.Schema, proxyCfg *config.HTTPProxyConfig) error
- func Variable(entity modelV1.VariableInterface, sch schema.Schema) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DashboardSpec ¶
DashboardSpec validates the dashboard spec. proxyCfg is the configuration of the HTTP proxy of the server, used to validate the proxy of the local datasources. It can be nil when the server configuration is not known (e.g. when linting offline). The server-dependent checks are then skipped.
func DashboardSpecWithVars ¶
func DashboardSpecWithVars(spec dashboard.Spec, sch schema.Schema, proxyCfg *config.HTTPProxyConfig, projectVariables []*modelV1.Variable, globalVariables []*modelV1.GlobalVariable) error
DashboardSpecWithVars is like DashboardSpec, but also takes into account the project and global variables.
func DashboardWithCustomRules ¶ added in v0.51.0
func DashboardWithCustomRules(dash *modelV1.Dashboard, customRules []*config.CustomLintRule) error
func Datasource ¶
func Datasource[T modelV1.DatasourceInterface](entity T, list []T, sch schema.Schema, proxyCfg *config.HTTPProxyConfig) error
Datasource validates the datasource. When list is not nil, it also verifies there is only one default datasource per kind. proxyCfg is the configuration of the HTTP proxy of the server, used to validate the proxy of the datasource. It can be nil when the server configuration is not known (e.g. when linting offline). The server-dependent checks are then skipped.
Types ¶
This section is empty.