[英]Unable to run PowerShell file as task in release pipeline - permission error
我正在嘗試將 PowerShell 腳本文件作為發布管道中的任務運行。 我嘗試了一個簡單的指令,如Write-Output "Hello World"
,腳本失敗並顯示消息
AuthorizationManager 檢查失敗。 CategoryInfo: SecurityError: (:) [], PSSecurityException FullyQualifiedErrorId: UnauthorizedAccess
如果我在 PowerShell 任務中運行內聯腳本,它會完美運行。
所以,我的問題是:我在 Visual Studio Team Services 中運行 PowerShell 腳本文件的用戶角色應該是什么?
問題是因為我試圖從共享驅動器運行腳本。 現在,我將文件本地復制到代理,然后一切正常。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.