Azure Devops Pipeline variables in Powershell
The issue is that you can't reference the changed value in the same task.
I created a new Powershell task and just called Write-Host &quot;env:IP environment variable set to ($env:IP)&quot; which output the IP address correctly.