Swoogan / Octopus-Cmdlets

A suite of PowerShell cmdlets that enable you to simplify and automate your interactions with an Octopus Deploy server.
40 stars 11 forks source link

Copying sensitive variables throws exception #2

Closed Swoogan closed 9 years ago

Swoogan commented 9 years ago
Get-OctoVariable "project" | ? {$_.Name -like "IIS.AppPool*"}  | Add-OctoLibraryVariable "variableset"
Add-OctoLibraryVariable : Octopus Server returned an error: String reference not set to an instance of a String.
Parameter name: s
Server exception:
System.ArgumentNullException: String reference not set to an instance of a String.
Parameter name: s
   at System.Text.Encoding.GetBytes(String s)
   at Octopus.Platform.Security.MasterKey.MasterKeyEncryptionExtensions.StringToCiphertext(IMasterKeyEncryption
encryption, String plaintext) in
y:\work\refs\heads\release\source\Octopus.Platform\Security\MasterKey\MasterKeyEncryptionExtensions.cs:line 13
   at Octopus.Server.Web.Api.Actions.VariableSetUpdateAction.Execute() in
y:\work\refs\heads\release\source\Octopus.Server\Web\Api\Actions\VariableSetUpdateAction.cs:line 100
   at Octopus.Platform.Web.Api.Responder`1.Respond(TDescriptor options, NancyContext context) in
y:\work\refs\heads\release\source\Octopus.Platform.Web\Api\Responder.cs:line 163
   at System.Dynamic.UpdateDelegates.UpdateAndExecute3[T0,T1,T2,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2)
   at CallSite.Target(Closure , CallSite , Object , Object , NancyContext )
   at Octopus.Server.Web.Api.OctopusRestApiModule.<>c__DisplayClass5.<.ctor>b__2(Object o) in
y:\work\refs\heads\release\source\Octopus.Server\Web\Api\OctopusRestApiModule.cs:line 47
   at CallSite.Target(Closure , CallSite , Func`2 , Object )
   at Nancy.Routing.Route.<>c__DisplayClass4.b__3(Object parameters, CancellationToken context)
-----------------------
At line:1 char:69
+ Get-OctoVariable "d2d server" | ? {$_.Name -like "IIS.AppPool*"}  | Add-OctoLibr ...
+                                                                     ~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Add-OctoLibraryVariable], OctopusServerException
    + FullyQualifiedErrorId : Octopus.Client.Exceptions.OctopusServerException,Octopus.Cmdlets.AddLibraryVariable
Swoogan commented 9 years ago

Seems to be resolved after updated client library, or by some other recent change