In a more global approach, you could look at the XTrigger Plugin. On Fri, Mar 30, 2012 at 10:15 PM, Simon Wiest <[email protected]> wrote:
> Hi, > > you could try to use the https://wiki.jenkins-ci.org/** > display/JENKINS/URLTrigger+**Plugin<https://wiki.jenkins-ci.org/display/JENKINS/URLTrigger+Plugin>instead > of the "Build Periodically" trigger. > > The URL trigger can periodically check if the content of an URL has > changed (any much more...). Your trigger URL should point to the artifact > you are relying on, e.g. http://<YOUR_JENKINS>/job/<**YOUR_BUILD_JOB>/** > lastSuccessfulBuild/artifact/<**YOUR_WEBAPP>.war. > > Does this work for you? > > Cheers, > Simon. > -- > candrews (30.03.2012 18:07): > > I have Jenkins configured to build and deploy a web application I'm >> working on as 2 projects: >> "Build" which compiles the application. It has "Archive the artifacts" >> set to save the resulting artifacts. >> "Deploy" which uses "Copy artifacts from another project" to get the >> artifacts from "Build" then deploy them to the server. The "Build >> Trigger" is set to "Build Periodically" every hour. >> >> The problem I'd like to solve is that the "Deploy" project does the >> deployment every hour - even if the the artifacts it's using from the >> "Build" project haven't changed. This means that in the middle of the >> night, when no one builds have been done, deploys are still happening. >> >> Is there any way I can make the "Deploy" project only run if the >> artifacts it depends on have changed? >> > >
