-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Lookup credentials on server in case job runs on remote node
On a remote node the configuration or credential store of Jenkins is not available. This gathers all values before hand and provides them via the context.
- Loading branch information
Showing
8 changed files
with
118 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,7 @@ | |
<parent> | ||
<groupId>org.jenkins-ci.plugins</groupId> | ||
<artifactId>plugin</artifactId> | ||
<version>3.19</version> | ||
<version>4.37</version> | ||
<relativePath /> | ||
</parent> | ||
|
||
|
@@ -32,8 +32,10 @@ | |
<url>https://wiki.jenkins-ci.org/display/JENKINS/AWSEB+Deployment+Plugin</url> | ||
|
||
<properties> | ||
<java.level>7</java.level> | ||
<jenkins.version>2.121.3</jenkins.version> | ||
<jenkins.version>2.289.3</jenkins.version> | ||
<java.level>8</java.level> | ||
<maven.compiler.source>1.8</maven.compiler.source> | ||
<maven.compiler.target>1.8</maven.compiler.target> | ||
</properties> | ||
|
||
<licenses> | ||
|
@@ -91,20 +93,13 @@ | |
<licenseName>apache_v2</licenseName> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>3.2</version> | ||
<configuration> | ||
<source>1.7</source> | ||
<target>1.7</target> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.jenkins-ci.tools</groupId> | ||
<artifactId>maven-hpi-plugin</artifactId> | ||
<extensions>true</extensions> | ||
<configuration> | ||
<compatibleSinceVersion>0.0.4</compatibleSinceVersion> | ||
<compatibleSinceVersion>1.45</compatibleSinceVersion> | ||
<minimumJavaVersion>8</minimumJavaVersion> | ||
</configuration> | ||
</plugin> | ||
</plugins> | ||
|
@@ -114,24 +109,29 @@ | |
<connection>scm:git:ssh://github.com/ingenieux/awseb-deployment-plugin.git</connection> | ||
<developerConnection>scm:git:ssh://[email protected]/ingenieux/awseb-deployment-plugin.git</developerConnection> | ||
<url>https://wiki.jenkins-ci.org/display/JENKINS/AWSEB+Deployment+Plugin</url> | ||
<tag>awseb-deployment-plugin-0.3.8</tag> | ||
<tag>awseb-deployment-plugin-0.3.22</tag> | ||
</scm> | ||
|
||
<dependencies> | ||
<dependency> | ||
<groupId>org.jenkins-ci.plugins</groupId> | ||
<artifactId>aws-credentials</artifactId> | ||
<version>1.23</version> | ||
<version>189.v3551d5642995</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.jenkins-ci.plugins</groupId> | ||
<artifactId>aws-java-sdk</artifactId> | ||
<version>1.11.341</version> | ||
<version>1.12.70</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.jenkins-ci.plugins</groupId> | ||
<artifactId>token-macro</artifactId> | ||
<version>2.1</version> | ||
<version>2.15</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.jenkins-ci</groupId> | ||
<artifactId>symbol-annotation</artifactId> | ||
<version>1.23</version> | ||
</dependency> | ||
<dependency> | ||
<groupId>org.jenkins-ci.main</groupId> | ||
|
@@ -141,7 +141,7 @@ | |
<dependency> | ||
<groupId>org.projectlombok</groupId> | ||
<artifactId>lombok</artifactId> | ||
<version>1.16.6</version> | ||
<version>1.18.24</version> | ||
<scope>provided</scope> | ||
</dependency> | ||
</dependencies> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
...ain/java/br/com/ingenieux/jenkins/plugins/awsebdeployment/AWSEBDeploymentCredentials.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
package br.com.ingenieux.jenkins.plugins.awsebdeployment; | ||
|
||
import com.amazonaws.auth.AWSCredentials; | ||
import com.amazonaws.auth.BasicAWSCredentials; | ||
import lombok.Data; | ||
|
||
import java.io.Serializable; | ||
|
||
@Data | ||
public class AWSEBDeploymentCredentials implements Serializable { | ||
private static final long serialVersionUID = 1L; | ||
|
||
public AWSEBDeploymentCredentials(String awsAccessKeyId, String awsSecretKey) { | ||
this.awsAccessKeyId = awsAccessKeyId; | ||
this.awsSecretKey = awsSecretKey; | ||
} | ||
|
||
/** | ||
* Access Key ID of credential | ||
*/ | ||
String awsAccessKeyId; | ||
|
||
/** | ||
* Secret Key of credential | ||
*/ | ||
String awsSecretKey; | ||
|
||
public AWSCredentials toAWSCredentials() { | ||
return new BasicAWSCredentials(awsAccessKeyId, awsSecretKey); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters