Created
September 1, 2016 21:09
-
-
Save alvarolobato/544465dd20b9351162ff3ac25be9df39 to your computer and use it in GitHub Desktop.
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
Started by user admin | |
[Pipeline] node | |
Running on linux in /home/ec2-user/jenkins/workspace/pipeline | |
[Pipeline] { | |
[Pipeline] sh | |
[pipeline] Running shell script | |
+ docker pull maven:latest | |
latest: Pulling from library/maven | |
Digest: sha256:f6becf58234086fa8cbfa89a38917ed3bec81baaac4465c3275d51ec22b60461 | |
Status: Image is up to date for maven:latest | |
[Pipeline] writeFile | |
[Pipeline] sh | |
[pipeline] Running shell script | |
+ docker inspect -f . maven:latest | |
. | |
[Pipeline] withDockerContainer | |
$ docker run -t -d -u 500:500 -w /home/ec2-user/jenkins/workspace/pipeline -v /home/ec2-user/jenkins/workspace/pipeline:/home/ec2-user/jenkins/workspace/pipeline:rw -v /home/ec2-user/jenkins/workspace/pipeline@tmp:/home/ec2-user/jenkins/workspace/pipeline@tmp:rw -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** -e ******** maven:latest cat | |
[Pipeline] { | |
[Pipeline] git | |
> git rev-parse --is-inside-work-tree # timeout=10 | |
Fetching changes from the remote Git repository | |
> git config remote.origin.url https://github.com/alvarolobato/maven_test.git # timeout=10 | |
Fetching upstream changes from https://github.com/alvarolobato/maven_test.git | |
> git --version # timeout=10 | |
> git -c core.askpass=true fetch --tags --progress https://github.com/alvarolobato/maven_test.git +refs/heads/*:refs/remotes/origin/* | |
> git rev-parse refs/remotes/origin/master^{commit} # timeout=10 | |
> git rev-parse refs/remotes/origin/origin/master^{commit} # timeout=10 | |
Checking out Revision ec51e83d2d80546f4781794b9a2c381792212369 (refs/remotes/origin/master) | |
> git config core.sparsecheckout # timeout=10 | |
> git checkout -f ec51e83d2d80546f4781794b9a2c381792212369 # timeout=10 | |
> git branch -a -v --no-abbrev # timeout=10 | |
> git branch -D master # timeout=10 | |
> git checkout -b master ec51e83d2d80546f4781794b9a2c381792212369 | |
> git rev-list ec51e83d2d80546f4781794b9a2c381792212369 # timeout=10 | |
[Pipeline] sh | |
[pipeline] Running shell script | |
Error response from daemon: Container c29f390cf3880278d2b49411834fd04b11b2632dd95aae094efcb01e6457d263 is not running | |
[Pipeline] } | |
$ docker stop c29f390cf3880278d2b49411834fd04b11b2632dd95aae094efcb01e6457d263 | |
$ docker rm -f c29f390cf3880278d2b49411834fd04b11b2632dd95aae094efcb01e6457d263 | |
[Pipeline] // withDockerContainer | |
[Pipeline] } | |
[Pipeline] // node | |
[Pipeline] End of Pipeline | |
ERROR: script returned exit code -2 | |
Finished: FAILURE |
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
node('linux'){ | |
//docker.image('maven:3.3.3-jdk-8').inside { | |
def maven = docker.image('maven:latest') | |
//def maven = docker.image('maven:3.3.3-jdk-8') | |
maven.pull() // make sure we have the latest available from Docker Hub | |
//maven.inside('-u root:root') { | |
writeFile file: 'file.txt', text: 'content_text' | |
maven.inside{ | |
git 'https://github.com/alvarolobato/maven_test.git' | |
sh 'mvn -B clean install' | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment