mirror of
https://github.com/tursom/TursomServer.git
synced 2024-12-26 12:50:24 +08:00
add Jenkinsfile
This commit is contained in:
parent
8e6d63617b
commit
fb0e9300c8
22
Jenkinsfile
vendored
Normal file
22
Jenkinsfile
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
pipeline {
|
||||
agent {
|
||||
docker {
|
||||
image 'openjdk:21'
|
||||
args '-v /root/.gradle:/root/.gradle'
|
||||
}
|
||||
}
|
||||
stages {
|
||||
stage('Build') {
|
||||
steps {
|
||||
sh './gradelw publish'
|
||||
script {
|
||||
try {
|
||||
archiveArtifacts artifacts: "**/build/libs/*.jar",fingerprint: true, followSymlinks: false, onlyIfSuccessful: true
|
||||
} catch (Exception err) {
|
||||
echo err.toString() /* hudson.AbortException: Couldn't find any revision to build. Verify the repository and branch configuration for this job. */
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user