Forced in content type json to make sure requests work

This commit is contained in:
Frikky
2026-02-11 12:51:21 +01:00
parent 136e54c8ed
commit f14011fb43
+4 -1
View File
@@ -4087,6 +4087,9 @@ func sendAppRequest(ctx context.Context, incomingUrl, appName string, port int,
} }
} }
// Content type required
req.Header.Set("Content-Type", "application/json")
newresp, err := client.Do(req) newresp, err := client.Do(req)
if err != nil { if err != nil {
// Another timeout issue here somewhere // Another timeout issue here somewhere
@@ -4108,7 +4111,7 @@ func sendAppRequest(ctx context.Context, incomingUrl, appName string, port int,
} }
if strings.Contains(fmt.Sprintf("%s", err), "no such host") { if strings.Contains(fmt.Sprintf("%s", err), "no such host") {
log.Printf("[DEBUG] SHOULD be Removing references to location for app %s as to be rediscovered", action.AppName) log.Printf("[ERROR] Should be removing references to location for app '%s' as to be rediscovered. URL: %s. Error: %s", action.AppName, streamUrl, err)
//for k, v := range portMappings { //for k, v := range portMappings {
// if strings.Contains(strings.ToLower(strings.ReplaceAll(action.AppName, " ", "_"))) { // if strings.Contains(strings.ToLower(strings.ReplaceAll(action.AppName, " ", "_"))) {