Skip to content

Commit 9d5389e

Browse files
authored
Merge pull request #113 from jstrachan/no-workspace
fix: handle running better outside of the controller
2 parents e2b2997 + 72ef41c commit 9d5389e

2 files changed

Lines changed: 7 additions & 3 deletions

File tree

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
<maven-surefire-plugin.version>2.22.1</maven-surefire-plugin.version>
3737
<mockwebserver.version>0.1.8</mockwebserver.version>
3838
<junit-jupiter-engine.version>5.6.2</junit-jupiter-engine.version>
39-
<jx-pipeline.version>0.0.120</jx-pipeline.version>
39+
<jx-pipeline.version>0.0.121</jx-pipeline.version>
4040
</properties>
4141

4242
<licenses>

src/main/java/org/waveywaves/jenkins/plugins/tekton/client/build/create/CreateRaw.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -367,12 +367,16 @@ private byte[] convertTektonData(FilePath workspace, EnvVars envVars, File input
367367
private byte[] processTektonCatalog(EnvVars envVars, File dir, File file, byte[] data) throws Exception {
368368
boolean deleteInputFile = false;
369369
if (file == null) {
370-
file = File.createTempFile("tekton-input-", ".yaml", dir);
370+
// the following fails when not running in the controller so lets not use a temp file for now
371+
//file = File.createTempFile("tekton-input-", ".yaml", dir);
372+
file = new File(dir, "tekton-input-pipeline.yaml");
371373
Files.write(data, file);
372374
logger.info("saved file: " + file.getPath());
373375
}
374376

375-
File outputFile = File.createTempFile("tekton-effective-", ".yaml", dir);
377+
// the following fails when not running in the controller so lets not use a temp file for now
378+
//File outputFile = File.createTempFile("tekton-effective-", ".yaml", dir);
379+
File outputFile = new File(dir, "tekton-effective-pipeline.yaml");
376380

377381
String filePath = file.getPath();
378382
String binary = ToolUtils.getJXPipelineBinary(getToolClassLoader());

0 commit comments

Comments
 (0)