Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-17644

Post build action execute even maven build was failed

XMLWordPrintable

      I configure job to execute shell script only in case if build was successfull on unstable. Using Execute Shell post build task.

      But when maven was failed (I noticed that only in case when java exception is appeared during build) I see such line in the log:

      20:52:04 Maven failed with error.
      20:52:04 channel stopped
      20:52:04 [CP-Master-Continuous] $ /bin/sh /tmp/hudson2733256445922844243.sh

      As you see maven failed, Jenkins is not mark build as FAILURE... Execute shell screen, and after it I see such lines in the log:
      20:52:09 Email was triggered for: Failure
      20:52:09 Sending email for trigger: Failure
      20:52:09 Sending email to: ....
      20:52:13 Finished: UNSTABLE

      Please notice that UNSTABLE is the status of previous build.

            mrebasti Marcelo Rebasti
            vkravets Vladimir Kravets
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: