BUG in Azure Automation Runtime Environment feature

Andrew 31 Reputation points
2024-06-13T08:41:30.0666667+00:00

There is a bug where if you want to test another (not published) Runtime by editing the Runbook, selecting the Runtime and hitting Test Pane and Start, the original (published) Runtime is used instead of the newly selected one.

In my example you can see that "bezcommon" Runtime is published.

User's image

Now lets say I want try to test the Runbook with "scommon" Runtime.

User's image

After starting the test run even the API call shows "scommon" as a used Runtime in the PUT request.

User's image

But the request response contains the published Runtime instead of the selected one as can be seen in the picture belowUser's image

And according to the test job results the published Runtime was used.

How to test this?

Create two runtimes:

Runtime 'With3rdPartyModule'

  • here import some 3rd party PowerShell module

Runtime 'Without3rdPartyModule'

  • don't import the 3rd party module

Create a Runbook with following PowerShell code: Get-Module -listavailable

In the Runbook choose 'With3rdPartyModule' Runtime, publish the change and run it.

Now edit the Runbook and choose the second a.k.a. 'Without3rdPartyModule' Runtime and run a test job.

Now compare the results. You should see that the result contains your 3rd party module outputted in both cases!

Azure Automation
Azure Automation
An Azure service that is used to automate, configure, and install updates across hybrid environments.
1,167 questions
{count} votes

Accepted answer
  1. Monalla-MSFT 12,761 Reputation points
    2024-06-17T13:57:06.14+00:00

    @Andrew & Jesus Chao - Welcome to Microsoft Q&A and thanks for reaching out to us.

    I have confirmation from our product team that this is a bug in this feature and our team had added this to the backlog and will be rolling this out in the next release and the ETA is 07/31.

    Hope this helps. and please feel free to reach out if you have any further questions.


    Please don't forget to "Accept as Answer" and click "Yes" if the above response is helpful, so it can be beneficial to the community.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful