microsoft / azure-pipelines-agent

Azure Pipelines Agent 🚀
MIT License
1.72k stars 864 forks source link

VSTS Agent doesn't know about powershell on Linux #592

Closed DieterE closed 8 years ago

DieterE commented 8 years ago

Agent version and platform


VSTS type and version

Account name http://quamotion.visualstudio.com

What's not working?

Adding a powershell task in a release definition for a Linux box which has Powershell installed (https://github.com/powershell/powershell)

There are issues with the release definition that may prevent deployment of release

Issues with Environment 'Webdriver QA1-LIN':

Issues with deploy phase 'Webdriver QA1-LIN' - No agents could be found that match the following demands (queue: 'QA'): DotNetFramework, agent.name -equals qm-qa-linux-01

Do you want to queue the release anyway?
2016-09-09T09:41:21.2340550Z ##[section]Starting: PowerShell Script
2016-09-09T09:41:21.3846000Z ##[error]Supported task execution handler not found. Supported handlers: Node
2016-09-09T09:41:21.3897210Z ##[section]Finishing: PowerShell Script
TingluoHuang commented 8 years ago

@DieterE from what i understand, there is no full .net powershell on linux. the agent's powershell task execution handler require full .net powershell.

bryanmacfarlane commented 8 years ago

Our powershell handlers are for desktop CLR powershell on windows. If and when we support xplat PS, it will be a new handler. Right now, it's win only task and script support

GuofuZhong commented 6 years ago

Hi @bryanmacfarlane do you have any plan to support linux powershell?

bryanmacfarlane commented 6 years ago

@GuofuZhong - to run in your build / release or to write tasks?

GuofuZhong commented 6 years ago

@bryanmacfarlane we use linux vsts agent, but we find it cannot work with powershell vsts task. although our linux installed powershell

bryanmacfarlane commented 6 years ago

@GuofuZhong - are you using the latest major version of the powershell task? Version is 2.x

https://github.com/Microsoft/vsts-tasks/blob/master/Tasks/powerShell/task.json#L5

GuofuZhong commented 6 years ago

Oh!! Thanks

GuofuZhong commented 6 years ago

@bryanmacfarlane Thanks!

olavoluissantos commented 6 years ago

hi @bryanmacfarlane, I've been trying to run a powershell script with the powershell vsts task. I'm on Ubuntu and I've got powershell and the vsts agent installed. My problem is very similar, output error points that there is no DotNetFramework installed. There is no DotNet Framework for linux, so how can I make this work? I've opened Task.json on https://github.com/Microsoft/vsts-tasks/tree/master/Tasks/PowerShellV2 and it says that the support for linux ps1 commands was added recently, so I believe that my TFS server has outdated tasks...how can I update them without screwing anything? I'm on a company and we used a remote server, so I don't even know if I have an easy access to it.