0

I'm deploying an application using ms release management and PS/DSC, but I have a manual step in the middle. This is causing me problems because I need to pass a variable from the first set of PS scripts to the second set that is executed after the manual steps.

I'm using TFS 2015 and RM 2015 on-premise.

I would like to not create an external system to store the data if possible.

Does anyone have any experience with this?

2 Answers 2

0

Basically, you can't. You could dump some JSON or XML or use an environment variable, but that's not ideal.

0

I managed to find a way to do this using the API. This isn't documented and is likely to break in the future, but it works for now. A warning, minimal validation is done on the RM side of this. You can change pretty much anything.

You have the release id as a parameter in the powershell script $ReleaseID

With this you can get the request object from the api using this GET call: http://.../account/releaseManagementService/_api/releaseManagement/ReleaseV2Service/Release?id=&api-version=6.0

Once you have that you can modify the custom variables for your stage and you can no pass that back and it will update the variables.

Use this API method and post the modified XML back http://.../account/releaseManagementService/_api/releaseManagement/ReleaseV2Service/SetRelease?api-version=6.0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.