Skip to content

Commit

Permalink
fix(k8s): if the output is json, stringify it (#1728)
Browse files Browse the repository at this point in the history
  • Loading branch information
ThePixelDeveloper authored Mar 25, 2020
1 parent 8f6d3c2 commit d62890d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions garden-service/src/plugins/kubernetes/status/pod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,10 @@ export async function getPodLogs({
}
}

if (typeof log === "object") {
log = JSON.stringify(log)
}

// the API returns undefined if no logs have been output, for some reason
return { containerName, log: log || "" }
})
Expand Down

0 comments on commit d62890d

Please sign in to comment.