Skip to content

Commit

Permalink
fix: Rename TS_WORKSPACE_DIR to TS_OUTPUT_DIR
Browse files Browse the repository at this point in the history
  • Loading branch information
banjoh committed Nov 9, 2023
1 parent 026cc91 commit fd67fdc
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions examples/collect/host/run-and-save-output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ spec:
# this is for demonstration purpose only -- you probably don't want to drop your input to the bundle!
args:
- "-c"
- "cat $TS_INPUT_DIR/dummy.yaml > $TS_WORKSPACE_DIR/dummy_content.yaml"
- "cat $TS_INPUT_DIR/dummy.yaml > $TS_OUTPUT_DIR/dummy_content.yaml"
outputDir: "myCommandOutputs"
env:
- AWS_REGION=us-west-1
Expand All @@ -23,7 +23,7 @@ spec:
dummy.conf: |-
[hello]
hello = 1
[bye]
bye = 2
dummy.yaml: |-
Expand Down
2 changes: 1 addition & 1 deletion pkg/collect/host_run.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func (c *CollectHostRun) Collect(progressChan chan<- interface{}) (map[string][]
return nil, errors.New(fmt.Sprintf("failed to create dir for: %s", runHostCollector.OutputDir))
}
cmd.Env = append(cmd.Env,
fmt.Sprintf("TS_WORKSPACE_DIR=%s", cmdOutputTempDir),
fmt.Sprintf("TS_OUTPUT_DIR=%s", cmdOutputTempDir),
)
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/collect/host_run_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ func TestCollectHostRun_Collect(t *testing.T) {
CollectorName: "my-cmd-with-output",
},
Command: "sh",
Args: []string{"-c", "echo ${TS_INPUT_DIR}/dummy.conf > $TS_WORKSPACE_DIR/input-file.txt"},
Args: []string{"-c", "echo ${TS_INPUT_DIR}/dummy.conf > $TS_OUTPUT_DIR/input-file.txt"},
Input: map[string]string{
"dummy.conf": "[hello]\nhello = 1",
},
Expand Down

0 comments on commit fd67fdc

Please sign in to comment.