Octopus-Cmdlets icon indicating copy to clipboard operation
Octopus-Cmdlets copied to clipboard

Feature Request - Adding -Sensitive parameter to Add-OctoLibraryVariable

Open hadynz opened this issue 7 years ago • 2 comments

There are two Add-OctoLibraryVariable commands that this project supports:

# Method 1
Add-OctoLibraryVariable [-VariableSet] <string> [-InputObject] <VariableResource[]>  [<CommonParameters>]

# Method 2
Add-OctoLibraryVariable [-VariableSet] <string> [-Name] <string> [[-Value] <string>] [-Environments <string[]>] [-Roles <string[]>] [-Machines <string[]>] [-Sensitive]  [<CommonParameters>]

I am trying to bulk copy variables (including sensitive ones) from a project to a variable set. For this purpose I am using Method 1 above, however, it doesn't currently support the -Sensitive flag.

Just raising it as a feature request to add to this project.

hadynz avatar Jun 22 '17 01:06 hadynz

The VariableResource itself has a IsSensitive flag. Does the first method not work for a straight copy?

Swoogan avatar Sep 25 '18 15:09 Swoogan

Actually, it looks like public VariableType Type { get; set; } was added and that is where the sensitive setting is now stored. It may be missing on the cmdlets due to using an old version of the client library. I will see if I can test this.

Swoogan avatar Sep 25 '18 15:09 Swoogan