feature/kjug
artifacts added
This commit is contained in:
parent
2a7b665d52
commit
3e5f628132
1 changed files with 53 additions and 10 deletions
43
Jenkinsfile
vendored
43
Jenkinsfile
vendored
|
@ -13,6 +13,25 @@ pipeline{
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Tests') {
|
stage('Tests') {
|
||||||
|
parallel {
|
||||||
|
stage('on centos') {
|
||||||
|
agent {
|
||||||
|
docker {
|
||||||
|
image 'qnib/pytest'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
steps {
|
||||||
|
sh 'ls -la'
|
||||||
|
sh 'pip install flask'
|
||||||
|
sh 'py.test --verbose --junit-xml test-reports/results.xml sources/test_webapp.py || true'
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
always {
|
||||||
|
junit 'test-reports/results.xml'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('on debian') {
|
||||||
agent {
|
agent {
|
||||||
docker {
|
docker {
|
||||||
image 'qnib/pytest'
|
image 'qnib/pytest'
|
||||||
|
@ -26,6 +45,30 @@ pipeline{
|
||||||
always {
|
always {
|
||||||
junit 'test-reports/results.xml'
|
junit 'test-reports/results.xml'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
stage('Create Artifacts') {
|
||||||
|
agent {
|
||||||
|
docker {
|
||||||
|
image 'cdrx/pyinstaller-linux:python2'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
steps {
|
||||||
|
sh 'pip install flask'
|
||||||
|
sh 'pyinstaller --paths=/usr/lib64/python2.7/site-packages/ --onefile sources/webapp.py'
|
||||||
|
stash includes: 'dist/webapp', name: 'exec_files'
|
||||||
|
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
success {
|
||||||
|
archiveArtifacts 'dist/webapp'
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue