0

I use Jenkins to run our builds. What I want to do is to wakeup the monitor before build starts. This is what I have done so far.

Use nircmdc.exe (http://www.nirsoft.net/utils/nircmd.html) and prepare a batch file to turn on monitor. I have tested the script through command prompt and it works fine.

Then I add a build step in Jenkins to execute windows batch file before running the ANT script. Then I remote start the build (via URL). Console shows that the batch file is being executed. But the monitors doesn't wake up.

Then I included a target in ANT to execute the same batch file and tested running the ANT via CMD. This wakes up the monitor and continue with the build steps.

But, if I run this ant script from Jenkins, everything works fine except waking up the monitor.

Is this something to do with privileges ?

Has someone done something similar?

user2058413
  • 691
  • 3
  • 10
  • 28

1 Answers1

1

Don't think I've ever heard of a requirement to wake up the monitor, so probably no one has done anything like this.

However, your problem is probably due to Jenkins process running in a separate session from your machine's console. Have a look at my answer here: Open Excel on Jenkins CI, it explains how to get around the session issue.

Community
  • 1
  • 1
Slav
  • 27,057
  • 11
  • 80
  • 104