Last active
August 29, 2015 14:17
-
-
Save makeittotop/c571568fd3ba149ed829 to your computer and use it in GitHub Desktop.
This tiny little gist queries status of most recent build for all jobs through the Jenkins cli
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # query jenkins CLI to get the status of most recent build for all jobs | |
| for job in `java -jar ~/Downloads/jenkins-cli.jar -s http://localhost:8080/ list-jobs 2> /dev/null`; do echo "Project: '$job' recent build status:"; java -jar ~/Downloads/jenkins-cli.jar -s http://localhost:8080/ console $job -f -n 1 2> /dev/null; done | |
| Example run :- | |
| unix> ... | |
| Project: 'copy-dev-dir-to-nas' recent build status: | |
| Finished: SUCCESS | |
| Project: 'disk-space-usage-fox-script' recent build status: | |
| Finished: SUCCESS | |
| Project: 'disk-space-usage-fox-tractor-host' recent build status: | |
| Finished: SUCCESS | |
| Project: 'disk-space-usage-lic-tractor-host' recent build status: | |
| Finished: SUCCESS | |
| Project: 'inventory-db-backup' recent build status: | |
| Finished: SUCCESS | |
| Project: 'render-space-usage-fox' recent build status: | |
| Finished: SUCCESS | |
| Project: 'tactic-db-backup' recent build status: | |
| Finished: SUCCESS | |
| Project: 'upload-inventory-db-dump-to-goog-nearline' recent build status: | |
| Finished: SUCCESS | |
| Project: 'upload-inventory-db-dump-to-s3' recent build status: | |
| Finished: SUCCESS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment