Update Jenkinsfile

This commit is contained in:
saisrinisrinivas 2023-07-04 12:59:59 +05:30 committed by GitHub
parent fb2c1b41d1
commit b19d695508
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

22
Jenkinsfile vendored
View file

@ -4,25 +4,21 @@ pipeline {
stages {
stage('S3Download') {
steps {
withAWS(region:'ap-south-1',credentials:'iamuser1')\
withAWS(region:'ap-south-1',credentials:'iamuser1')
{
s3Download(file: 'Jenkinsfile', bucket: 'myjenkinsbucket001', path: 'https://myjenkinsbucket001.s3.ap-south-1.amazonaws.com/Jenkinsfile')
// Download the S3 object
sh 'aws s3 cp s3://myjenkinsbucket001/Jenkinsfile /tmp/bucketfile'
// Execute the downloaded script
sh 'chmod +x /tmp/bucketfile'
sh '/tmp/bucketfile
}
}
}
stage('GitCheckout'){
steps {
git 'https://github.com/saisrinisrinivas/spring-petclinic.git'
}
}
stage('Run'){
steps {
sh 'mvn package'
}
}
}
}