forked from bluesentry/bucket-antivirus-function
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Jenkinsfile
38 lines (37 loc) · 1.11 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
pipeline {
agent any
stages {
stage('Build') {
// agent {
// docker {
// image 'amazonlinux:latest'
// args '--volume $(pwd):/opt/app'
// args '/bin/bash -c "cd /opt/app && ./build_lambda.sh"'
// }
// }
steps {
sh 'echo $(date +"%F %T") - Configuring Build environment using docker..'
sh '''
docker run --rm -i \
--name lambda_build \
--volume $(pwd):/opt/app \
amazonlinux:latest \
/bin/bash -c "cd /opt/app && ./build_lambda.sh"
'''
sh 'ls -larth'
sh 'ls -larth build/'
sh 'echo $(date +"%F %T") - Build completed successfully'
}
}
stage('Test') {
steps {
sh 'echo $(date +"%F %T") - Starting Tests in LAB...'
}
}
stage('Deploy') {
steps {
echo 'Deploying....'
}
}
}
}