Hi, We have been use Octopus deploy for a while. We use the following script to do the swapping of slots:
$ParametersObject = @{targetSlot = “production”}
Invoke-AzureRmResourceAction -ResourceGroupName #{web-app-resource-group} -ResourceType Microsoft.Web/sites/slots -ResourceName #{web-app-target-ui-soar}/Staging -Action slotsswap -Parameters $ParametersObject -ApiVersion 2015-07-01 -Force
This morning, we suddenly run into a problems in this step. It is complaining the following. Any insight would be highly appreciated.
Octopus Server version: 3.3.8+Branch.master.Sha.ce74fb45b4197c055b4a7cb8799ae9d048b1dce2
11:33:47
Verbose
Using account ID ‘Octopus Deployment V4’
11:33:48
Verbose
Octopus Deploy: Calamari.Azure version 3.3.8+Branch.master.Sha.2d50790e95504aafbed8cc4a0b80c586fa074f18
11:34:00
Error
At D:\Octopus\Work\20160822163347-1782\Bootstrap.Octopus.AzureContext.ps1:1476 char:9
11:34:00
Error
-
If (Test-Path #{Octopus.Tentacle.Agent.ApplicationDirectoryPath}\current ...
11:34:00
Error
-
~~
11:34:00
Error
Missing closing ‘)’ after expression in ‘If’ statement.
11:34:00
Error
At D:\Octopus\Work\20160822163347-1782\Bootstrap.Octopus.AzureContext.ps1:1477 char:13
11:34:00
Error
-
New-OctopusArtifact -Path #{Octopus.Tentacle.Agent.ApplicationDirect ...
11:34:00
Error
-
~~~~~~~~~~~~~~~~~~~
11:34:00
Error
Missing closing ‘)’ after expression in ‘If’ statement.
11:34:00
Error
At D:\Octopus\Work\20160822163347-1782\Bootstrap.Octopus.AzureContext.ps1:1482 char:1
11:34:00
Error
- }
11:34:00
Error
- ~
11:34:00
Error
Unexpected token ‘}’ in expression or statement.
11:34:00
Error
At D:\Octopus\Work\20160822163347-1782\Bootstrap.Octopus.AzureContext.ps1:1484 char:1
11:34:00
Error
- } | Import-Module
11:34:00
Error
- ~
11:34:00
Error
Unexpected token ‘}’ in expression or statement.