Skip to content

Commit

Permalink
fix(k8s): artifact logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Mitchell Friedman authored and edvald committed Apr 21, 2020
1 parent 28ded99 commit 7fd02d0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion garden-service/src/plugins/kubernetes/run.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ export async function runAndCopy({

// We start the container with a named pipe and tail that, to get the logs from the actual command
// we plan on running. Then we sleep, so that we can copy files out of the container.
spec.containers[0].command = ["sh", "-c", "mkfifo /tmp/output && tail -f /tmp/output && sleep 86400"]
spec.containers[0].command = ["sh", "-c", "mkfifo /tmp/output && cat /tmp/output && sleep 86400"]
} else {
if (args) {
spec.containers[0].args = args
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ describe("kubernetes container module handlers", () => {
timeout: 3,
})

expect(result.log.trim()).to.equal("Command timed out.")
expect(result.log.trim()).to.equal("Command timed out. Here are the logs until the timeout occurred:\n\nbanana")
expect(result.success).to.be.false
})

Expand Down

0 comments on commit 7fd02d0

Please sign in to comment.