How to run CruiseControl.NET task, but only after completion of a specific task?

For example, I have three tasks: task1, task2, task3. How to write a CruiseControl.NET configuration file that launches task3, but only after task2 successfully completes?

+3
source share
4 answers

CruiseControl.NET v1.5 improves the execution of tasks using their new tasks Sequential and Parallel ...

http://confluence.public.thoughtworks.org/display/CCNET/Sequential+Task

<sequential continueOnFailure="false">
  <description>Example of how to run multiple tasks in sequence.</description>
  <tasks>
    <!-- Tasks defined here -->
  </tasks>
</sequential>
+5
source

Depending on what you are trying to accomplish, this can be done quite easily in two ways:

A) CruiseControl.NET , projectTriggers:

, . task3 task2. task2 , task3 . Trigger, task3 ccnet.config :

<triggers>
  <multiTrigger>
    <triggers>
      <intervalTrigger seconds="30" />
      <projectTrigger project="task2">
        <triggerStatus>Success</triggerStatus>
      </projectTrigger>
    </triggers>
  </multiTrigger>
</triggers>

B) Nant:

Wim, Nant-, ccnet.config. , , , .

+4

I suggest that you do this inside an NAnt or MSBuild task instead and pull it out of the CruiseControl.NET configuration.

What do your tasks do? Any reasons why you cannot move them inside an NAnt or MSBuild script?

+2
source

I would recommend a script file (bat, PowerShell ), where you run tasks and check success.

0
source

Source: https://habr.com/ru/post/1722735/


All Articles