oclib update + casual debug
This commit is contained in:
@@ -9,8 +9,6 @@ import (
|
||||
)
|
||||
|
||||
type LocalMonitor struct {
|
||||
LokiURL string
|
||||
KubeURL string
|
||||
ExecutionID string
|
||||
PeerID string
|
||||
Duration int
|
||||
@@ -18,15 +16,17 @@ type LocalMonitor struct {
|
||||
}
|
||||
|
||||
func (lm *LocalMonitor) LaunchLocalMonitor() {
|
||||
if lm.LokiURL == "" || lm.KubeURL == "" || lm.ExecutionID == "" {
|
||||
if lm.ExecutionID == "" {
|
||||
lm.Logger.Error().Msg("Missing parameter in LocalMonitor")
|
||||
}
|
||||
lm.execKube()
|
||||
}
|
||||
|
||||
func (lm *LocalMonitor) execKube() {
|
||||
args := []string{"-e", lm.ExecutionID, "-p", lm.PeerID, "-u", lm.LokiURL, "-m", conf.GetConfig().MongoUrl,
|
||||
"-d", conf.GetConfig().DBName}
|
||||
args := []string{
|
||||
"-e", lm.ExecutionID, "-p", lm.PeerID, "-u", conf.GetConfig().LokiUrl, "-m", conf.GetConfig().MongoUrl,
|
||||
"-d", conf.GetConfig().DBName,
|
||||
}
|
||||
|
||||
if conf.GetConfig().Mode == "kubernetes" {
|
||||
args = append(args, []string{"-M", conf.GetConfig().Mode, "-H", conf.GetConfig().KubeHost, "-P", conf.GetConfig().KubePort,
|
||||
|
||||
@@ -2,7 +2,6 @@ package daemons
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"oc-schedulerd/conf"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
@@ -52,8 +51,6 @@ func (em *ExecutionManager) executeExecution(Execution *workflow_execution.Workf
|
||||
monitor := LocalMonitor{
|
||||
Logger: logger,
|
||||
Duration: duration,
|
||||
LokiURL: conf.GetConfig().LokiUrl,
|
||||
KubeURL: "localhost",
|
||||
ExecutionID: Execution.UUID,
|
||||
PeerID: Execution.CreatorID,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user