Skip to content
Permalink
Browse files
Merge pull request #19 from ericNdfw/master
JENKINS-13897 EC2 Userdata not being Base64 encoded
  • Loading branch information
francisu committed May 25, 2012
2 parents a60b548 + 4f79870 commit 35b201e0421179f2074aba85f0fc7a2a36c6b666
Showing 1 changed file with 2 additions and 1 deletion.
@@ -24,6 +24,7 @@

import javax.servlet.ServletException;

import org.apache.commons.codec.binary.Base64;
import org.apache.commons.lang.StringUtils;
import org.kohsuke.stapler.DataBoundConstructor;
import org.kohsuke.stapler.QueryParameter;
@@ -174,7 +175,7 @@ public EC2Slave provision(TaskListener listener) throws AmazonClientException, I
Placement placement = new Placement(getZone());
request.setPlacement(placement);
}
request.setUserData(userData);
request.setUserData(Base64.encodeBase64String(userData.getBytes()));
request.setKeyName(keyPair.getKeyName());
request.setInstanceType(type.toString());
request.setSecurityGroups(securityGroupSet);

0 comments on commit 35b201e

Please sign in to comment.