jabbera / my-vsts-tasks

20 stars 18 forks source link

Register-Environment not recognized as cmdlet name, function........ #7

Closed larikitty closed 7 years ago

larikitty commented 7 years ago

Getting this error on VSTS online release management on new release:

2016-11-17T11:24:05.9337547Z ##[section]Starting: Stop Windows Service: OTFTPMonitor and OTFTPImport 2016-11-17T11:24:05.9887547Z Preparing task execution handler. 2016-11-17T11:24:06.9457547Z Executing the powershell script: C:\agent\w_tasks\StopWindowsService_601cd43e-b65d-49b7-b118-091333bd5b9f\1.16271.0\StopWindowsService.ps1 2016-11-17T11:24:06.9507547Z Stopping Windows Service: and setting startup type to: Manual. Kill: true Version: 1.16271.0 2016-11-17T11:24:06.9507547Z ScriptArguments: -serviceNames "OTFTPMonitor, OTFTPImport" -startupType Manual -waitTimeoutInSeconds 120 -killIfTimedOut true 2016-11-17T11:24:06.9517547Z 2016-11-17T11:24:06.9517547Z 2016-11-17T11:24:06.9517547Z Invoking deployment 2016-11-17T11:24:09.6467547Z ##[error]System.Management.Automation.CommandNotFoundException: O termo 'Register-Environment' não é reconhecido como nome de cmdlet, função, arquivo de script ou programa operável. Verifique a grafia do nome ou, se um caminho tiver sido incluído, veja se o caminho está correto e tente novamente. 2016-11-17T11:24:09.6477547Z em System.Management.Automation.ExceptionHandlingOps.CheckActionPreference(FunctionContext funcContext, Exception exception) 2016-11-17T11:24:09.6477547Z em System.Management.Automation.Interpreter.ActionCallInstruction2.Run(InterpretedFrame frame) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.Interpreter.EnterTryCatchFinallyInstruction.Run(InterpretedFrame frame) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.Interpreter.Interpreter.Run(InterpretedFrame frame) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.Interpreter.LightLambda.RunVoid1[T0](T0 arg0) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.PSScriptCmdlet.RunClause(Action1 clause, Object dollarUnderbar, Object inputToProcess) 2016-11-17T11:24:09.6487547Z em System.Management.Automation.PSScriptCmdlet.DoEndProcessing() 2016-11-17T11:24:09.6487547Z em System.Management.Automation.CommandProcessorBase.Complete() 2016-11-17T11:24:09.6747547Z ##[error]PowerShell script completed with 1 errors. 2016-11-17T11:24:09.6757547Z ##[section]Finishing: Stop Windows Service: OTFTPMonitor and OTFTPImport

jabbera commented 7 years ago

I was getting that on OnPrem with TFS 15 RC. I'll push an update when I get to work. I'll be interested if it fixes the issue.

jabbera commented 7 years ago

I've published a new version. Let me know if it resolves your issue.

jabbera commented 7 years ago

Closing due to lack of response.

larikitty commented 7 years ago

Sorry. I'll test and let you know. I haven't builded the app after this.

jabbera commented 7 years ago

No worries. Take your time. If the issue happens again feel free to re-open,