Skip to content
Permalink
Browse files
JENKINS-26531 Slave does not start if the temp dir is not set to
anything after upgrade to 1.25
  • Loading branch information
Francis Upton IV committed Jan 27, 2015
1 parent 8fc0046 commit 535704775e2505f29a98596884ce4b8ae7c8ee75
Showing 1 changed file with 3 additions and 1 deletion.
@@ -23,6 +23,7 @@
*/
package hudson.plugins.ec2.ssh;

import hudson.Util;
import hudson.ProxyConfiguration;
import hudson.model.Descriptor;
import hudson.model.Hudson;
@@ -40,6 +41,7 @@
import java.net.URL;

import jenkins.model.Jenkins;

import org.apache.commons.io.IOUtils;

import com.amazonaws.AmazonClientException;
@@ -102,7 +104,7 @@ else if (bootstrapResult == SAMEUSER) {

SCPClient scp = conn.createSCPClient();
String initScript = computer.getNode().initScript;
String tmpDir = (computer.getNode().tmpDir != null ? computer.getNode().tmpDir : "/tmp");
String tmpDir = (Util.fixEmptyAndTrim(computer.getNode().tmpDir) != null ? computer.getNode().tmpDir : "/tmp");

logger.println("Creating tmp directory (" + tmpDir + ") if it does not exist");
conn.exec("mkdir -p " + tmpDir, logger);

0 comments on commit 5357047

Please sign in to comment.