Functions/Private/Get-RancherServer.ps1

1
2
3
4
5
6
7
8
9
10
11
12
13
14
function Get-RancherServer {
    [CmdletBinding()]
    param()

    if (-Not (Test-RancherServer)) {
        throw 'Credentials not set. Please use Set-RancherServer first.'
    }

    @{
        Server    = $script:RancherServer
        AccessKey = $script:RancherAccessKey
        SecretKey = $script:RancherSecretKey
    }
}