jenkins-automaintenance/Jenkinsfile

25 lines
430 B
Plaintext
Raw Normal View History

pipeline {
2024-10-11 08:31:26 -04:00
agent {
label 'agent2'
}
triggers {
cron("59 23 * * 1") // Clean up every monday
}
options {
buildDiscarder(logRotator(numToKeepStr: '10', artifactNumToKeepStr: '10'))
}
stages {
2024-10-11 08:31:26 -04:00
stage('Clean docker images') {
steps {
sh 'docker system prune -a -f'
sh 'docker network prune -f'
}
}
}
}