Powershell on Linux

cloud
reliability
known
(André Bires) #1

Dear sirs, since update to version 2019.10, Octopus is supporting Powershell Core, and the current behavior on Linux breaks our package installation: we bundle .NET Core with scripts .ps1 (previously, only for Windows) and .sh (only Linux) on same package, since this should be cross-platform.

Now our Linux targets fail to deploy since Octopus try to run .ps1 script on they.

There is a way to disable this behaviour? If not, Octopus should at least check if Powershell Core is installed before trying to run .ps1 scripts…

(Daniel Fischer) #5

Hi @andrebires,

Thanks for getting in touch! Currently this is something we are looking into solutions for. We were aware that having multiple deploy scripts in your package will cause this issue while introducing the feature. I think there are currently limited solutions available.

Octopus will always try to execute both the .ps1 and .sh scripts during the deployment.

The best option currently would be to rename the file with a custom script before we try to execute it. The other option would be to remove the .ps1 script on your Linux targets.

We are aware that these are not great workarounds and are currently looking into how we can better handle this.

If you have any thoughts or questions here at all, please don’t hesitate to let me know.

Best regards,
Daniel