fix(k8s): pass SHUFFLE_LOGS_DISABLED env var from orborus -> worker -> app

Signed-off-by: Pascal Sthamer <10992664+P4sca1@users.noreply.github.com>
This commit is contained in:
Pascal Sthamer
2025-08-20 11:21:00 +02:00
parent 0bf0736d07
commit feaee08333
2 changed files with 25 additions and 18 deletions
+6 -3
View File
@@ -818,7 +818,7 @@ func handleBackendImageDownload(ctx context.Context, images string) error {
// Force: true,
// PruneChildren: true,
// })
//
// if err != nil {
// log.Printf("[ERROR] Failed removing image for re-download: %s", err)
// } else {
@@ -827,7 +827,7 @@ func handleBackendImageDownload(ctx context.Context, images string) error {
// } else {
// //log.Printf("[DEBUG] Skipping image removal for %s as swarmConfig is not set to run or swarm. Value: %#v", curimage, swarmConfig)
// }
//
err := shuffle.DownloadDockerImageBackend(&http.Client{Timeout: imagedownloadTimeout}, curimage)
if err != nil {
//log.Printf("[ERROR] Failed downloading image: %s", err)
@@ -1065,6 +1065,10 @@ func deployK8sWorker(image string, identifier string, env []string) error {
env = append(env, fmt.Sprintf("SHUFFLE_APP_CONTAINER_SECURITY_CONTEXT=%s", appContainerSecurityContext))
}
if len(os.Getenv("SHUFFLE_LOGS_DISABLED")) > 0 {
env = append(env, fmt.Sprintf("SHUFFLE_LOGS_DISABLED=%s", os.Getenv("SHUFFLE_LOGS_DISABLED")))
}
clientset, _, err := shuffle.GetKubernetesClient()
if err != nil {
log.Printf("[ERROR] Error getting kubernetes client:", err)
@@ -2214,7 +2218,6 @@ func main() {
log.Printf("[INFO] Waiting for executions at %s with Environment %#v", fullUrl, environment)
hasStarted := false
for {
if req.Method == "POST" {
+4
View File
@@ -422,6 +422,10 @@ func deployk8sApp(image string, identifier string, env []string) error {
envMap["SHUFFLE_SWARM_CONFIG"] = os.Getenv("SHUFFLE_SWARM_CONFIG")
envMap["BASE_URL"] = "http://shuffle-workers:33333"
if len(os.Getenv("SHUFFLE_LOGS_DISABLED")) > 0 {
envMap["SHUFFLE_LOGS_DISABLED"] = os.Getenv("SHUFFLE_LOGS_DISABLED")
}
clientset, _, err := shuffle.GetKubernetesClient()
if err != nil {
log.Printf("[ERROR] Failed getting kubernetes: %s", err)