Desktop Application Not Interactable on Virtual Machine- what setting am I missing?

Randy Dobbs 1 Reputation point
2022-02-23T22:05:18.013+00:00

Hello there

I have a series of Azure Pipelines, for regression automation, configured to run on two Azure VM's which run a desktop application, using WinAppDriver.

Please note- once the agent starts, it fires off another user (with admin rights) in a pseudo-terminal server due to session 0 (this gets me around that issue.)

Currently- when these builds are triggered, the app will launch, but the user is unable to interact with the application.
However, if I log into the VM, then log in again as the elevated user, engage the pipeline- I can watch the tests run as expected, with full interactivity.

Here's the trick - I logout of the elevated user using a powershell script, sign off of the VM, engage that same pipeline- the pipeline will run as expected, with full interactivity.
After 15 minutes, this will cease- if I engage the pipeline, I once again return to being unable to interact with the application.

It would seem that I am missing a setting somewhere for that Azure VM to consistently allow user accessibility? Can you point me in a direction?
I do not see any Errors in the Event Viewer that would cause this failure.

I thank you for your time
Randy

Azure Virtual Machines
Azure Virtual Machines
An Azure service that is used to provision Windows and Linux virtual machines.
7,891 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Randy Dobbs 1 Reputation point
    2022-03-03T13:10:39.997+00:00

    I was able to resolve this issue.

    It was a combination of Group Policy + Registry settings:
    1.) Disable ScreenSaver in GPO
    2.) Set Session Time Limit to "Never" in GPO
    3.) Set the Idle time to 208 days (maximum value) in registry
    4.) This was on top of the graphics settings that were necessary to accommodate proper desktop application usage.

    The VM's are behind multiple firewall layers + are reset often enough due to security/windows updates that these settings allow to maintain a consistent agent connection for a week or 2- which is far far better than 15 minutes.

    Thank you
    Randy

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.