From 071decd62d62a9f15931d7d906954165c5b0c857 Mon Sep 17 00:00:00 2001 From: Nithunikzz Date: Fri, 15 Sep 2023 09:30:54 +0530 Subject: [PATCH] Added schedule --- agent/config/config.go | 2 +- agent/kubviz/k8smetrics_agent.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/agent/config/config.go b/agent/config/config.go index 53abb572..50209ccd 100644 --- a/agent/config/config.go +++ b/agent/config/config.go @@ -14,7 +14,7 @@ type AgentConfigurations struct { RakkessInterval string `envconfig:"RAKKESS_INTERVAL" default:"*/50 * * * *"` KubePreUpgradeInterval string `envconfig:"KUBEPREUPGRADE_INTERVAL" default:"*/60 * * * *"` TrivyInterval string `envconfig:"TRIVY_INTERVAL" default:"*/10 * * * *"` - Scheduler bool `envconfig:"SCHEDULER" default:"true"` + SchedulerEnable bool `envconfig:"SCHEDULER_ENABLE" default:"false"` } func GetAgentConfigurations() (serviceConf *AgentConfigurations, err error) { diff --git a/agent/kubviz/k8smetrics_agent.go b/agent/kubviz/k8smetrics_agent.go index a27149a5..7bfda9bc 100644 --- a/agent/kubviz/k8smetrics_agent.go +++ b/agent/kubviz/k8smetrics_agent.go @@ -134,7 +134,7 @@ func main() { } collectAndPublishMetrics() - if cfg.Scheduler { // Assuming "cfg.Schedule" is a boolean indicating whether to schedule or not. + if cfg.SchedulerEnable { // Assuming "cfg.Schedule" is a boolean indicating whether to schedule or not. scheduler := initScheduler(config, js, *cfg, clientset) // Start the scheduler