Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

Retrieve Action Group Server Assignment From Child Action



  • Is there any way to retrieve the Server Name of the parent Action Group if the assigned server to a child task is different? For example, if I assign a child task to Server B, the $ServerName variable will have a value of Server B since that is currently scoped. However, if the parent Action Group has an assignment of Server A, I would like to be able to retrieve that server assignment. Is there any way to accomplish that?

    Product: BuildMaster
    Version: 4.4.2



  • There's no direct way to do this yet (perhaps we can add a system variable or something in the future), however you can work around this by adding an action group above the one you want to name that uses a Set Variable Value action with the configuration: Set $ActionGroupServerName = YourGroup.

    Then, you can assign your existing action group to the server $ActionGroupServerName (i.e. a variable server), and you will be able to access $ActionGroupServerName within that group to get the name of the action group's server.



  • Similar to what you said, I can use the first step in the Action Group to set a different variable to the value in $ServerName, which should give me the name of the Action Group scoped server. Is the $ServerName variable scoped within each Action Group? For example, if I have Action Groups executing in parallel, is it guaranteed that the $ServerName variable will be scoped within each individual Action Group and there will not be any crossover of this variable? If not, I would likely have to use a different variable name for each Action Group where I need this functionality.



  • When run in parallel, there is no guarantee with the ordering the value is set (and the change would be observed in different groups), so you'd have to create separate variables in each group if you have multiple action groups using different server groups.



Inedo Website HomeSupport HomeCode of ConductForums GuideDocumentation