Distribution of this plugin has been suspended due to unresolved security vulnerabilities, see below.
The current version of this plugin may not be safe to use. Please review the following warnings before use:
This plugin is up for adoption. Want to help improve this plugin? Click here to learn more!
ScriptTrigger makes it possible to monitor an environment with a script.
The ScriptTrigger plug-in enables you to configure the polling predicate by the evaluation of a script.
Two types of script are supported
* Groovy script
If the expression evaluation returns true, a build is scheduled.
* Shell or Windows Batch script
A script is executed and a build is scheduled if the exit code matches your expected exit code.
For both types, if the script execution output contains the content <cause>YOUR_SCHEDULED_CAUSE</cause>, 'YOUR_SCHEDULED_CAUSE' is used as the build cause.
Additionally, if the script execution output contains the content <description>MY DESCRIPTION</description>, the 'MY DESCRIPTION' value is attached to the run.
Note: The plug-in uses only persistence in memory. There is no impact on the Jenkins infrastructure (no new files created).
This plugin provides a polling typology among the XTrigger Plugin.
Impossible to combine it with EnvInject plugin
Script Trigger plugin enables you to run an external script for knowing if job has to be scheduled, whereas EnvInject enables you to control environment variables when the job runs. Therefore, scripttrigger and EnvInject have 2 disctinct objectives. In conclusion, it is not possible to exploit envinject configuration. Your Script has to be standalone and independent from the job. Export your environment variables directly from your script.
* Fix JENKINS-33328 - Cannot run trigger script on a slave node
* Fix JENKINS-31017 - Description doesn't get the resolved variable
* Add a MIT Lisence for all sources
* Fix JENKINS-19379 - The scripttrigger plugins fails to load the parameter files when the System script is in use.
* Fix JENKINS-18667 - NullPointerException when saving job config
* Adding envvar replacement for groovyFilePath
* Fix JENKINS-17641 \ Unknown field 'logEnabled' in org.jenkinsci.lib.xtrigger.XTriggerCause
* Fix reopened JENKINS-17566 - Severe polling error when using script trigger
* Fix JENKINS-17566 - Severe polling error when using script trigger
* Test if the node is active when the polling do the work
* Updat to xtrigger-lib 0.20
** Refactor error management
* Fix polling issue by updating to org.jenkins-ci.lib:xtrigger-lib:jar:0.19:compile
* Re-adding newLine to line read in script content
* Fix JENKINS-14535 - Fails to poll when no executors on master
* Fix JENKINS-14104 - Use same node which has been specified in the "Restrict where this project can be run" field
* Try to delete generated temporary file
* Upgrade to xtrigger-lib 0.12
* Add an option to have concurrent builds
* Update to xtrigger-lib 0.11
* Fix JENKINS-13542 - Backslashes in Environment / Script-Variables are not quoted correctly for Groovy
* Update to xtrigger-lib 0.10
- Add system script checkbox in configuration UI
- Add log/out/job variables to groovy shell
- Setup the SYSTEM user during script execution
- Log envvars used for script re-writing
- Log messages and stack traces if the groovy script fails
* Update to xtrigger-lib 0.8
* Update to xtrigger-lib 0.7
* Fixed JENKINS-11907 - scripttrigger doesn't close file
* Environment variables are taken into account
* Removed duplicate script resolution
* Added cause and description attachment if they are present in the script execution output
* Added the ability to inject environment variables with the EnvInject Plugin.
* Added environment and job variables resolution to the script content
* Fixed JENKINS-11042 - IOException when running ScriptTrigger with slaves
* Built for 1.409 (LTS series compatibility)
* Fixed log polling file
* Fixed script execution node
* Added Jenkins environment variables resolution in script execution
* Added the ability to provide scripts with a file path
* Fixed a hep plugin message
* Added a polling an the exit code of a shell script or a Windows batch script.
* Improved help files
* Added a check: executing the script only if the Jenkins instance is not isQuietingDown() and the job is buildable
* Added the feature: 'Can specify job properties as a properties file'
* Initial release