We are using Octopus cloud, and have a pretty simple configuration where we deploy to an Azure WebApp using a deployment target. We then follow up the deployment with an Azure powershell script step that tweaks certain things in the app according to tenant variables.
However, we haven’t been able to access the target WebApp name (or slot name) in the powershell script using Octopus variables. We’re attempting to do the following:
Thanks for getting in touch! That’s great to hear you’ve been able to resolve this by embedding it into the web app step. It looks like the reason why it wasn’t working in the standalone script step is because the step name that populates these system variables wasn’t specified in the variable. Something like this should work in this case: