-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathJenkinsfile
More file actions
29 lines (26 loc) · 871 Bytes
/
Jenkinsfile
File metadata and controls
29 lines (26 loc) · 871 Bytes
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
node('docker'){
stage ('scm') {
checkout(scm)
}
stage ('test') {
sh 'make test-with-coverage'
}
stage ('publish') {
withCredentials([usernamePassword(credentialsId: 'GitHub-Jenkins', usernameVariable: 'GIT_USERNAME', passwordVariable: 'GIT_PASSWORD')]) {
withCredentials([usernamePassword(credentialsId: 'pypi-modelon-api-key', usernameVariable: 'PYPI_USERNAME', passwordVariable: 'PYPI_PASSWORD')]) {
env.GIT_CREDENTIALS = "${GIT_USERNAME}:${GIT_PASSWORD}"
env.PYPI_USERNAME = "${PYPI_USERNAME}"
env.PYPI_PASSWORD = "${PYPI_PASSWORD}"
sh 'make publish'
}
publishHTML (target: [
allowMissing: false,
alwaysLinkToLastBuild: false,
keepAll: true,
reportDir: 'htmlcov',
reportFiles: 'index.html',
reportName: "Test coverage report"
])
}
}
}