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

Cleaning VM before start next job in queue.

XMLWordPrintable

      Sylvain Chagnaud says: Hi, it's a very useful plugin. But I have a little comment for a specific case. ...
      Hi, it's a very useful plugin. But I have a little comment for a specific case. In fact I want to revert to a snapshot before each job execution but if several jobs try to run on the VMWare at the same time then the VMWare can't revert to the snapshot. Do you have a solution, thank you ?

      jswager - says: At the moment, I don't have a solution incorporated into the plugin. But I...
      At the moment, I don't have a solution incorporated into the plugin. But I'm working on it. In the meantime, here's a workaround:
      1) Configure the slave with a disconnect type of Revert or Reset.
      2) In your test job, mark the slave temporarily offline. This will prevent further jobs from targeting the slave. It would be something like this:
      curl -d "offlineMessage=back_in_a_moment&json=%7B%22offlineMessage%22%3A+%22back_in_a_moment%22%7D&Submit=Mark+this+node+temporarily+offline" http://JENKINS_HOST/computer/NODE_TO_DISCONNECT/toggleOffline
      3) As a final step in your job, start a delayed shutdown of the VM. If it's Windows, something like "shutdown /s /t

            Unassigned Unassigned
            larsky Alexey Larsky
            Votes:
            4 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated: