Initialize-HarborConfig
First-run setup wizard. Captures tenant details and writes a gitignored environment.local.json so a new client install reaches “ready” without hand-editing JSON.
Syntax
Section titled “Syntax”Initialize-HarborConfig [[-ProfileName] <string>] [[-TenantName] <string>] [[-TenantId] <string>] [[-PvwaUrl] <string>] [[-IdentityUrl] <string>] [[-OAuthClientId] <string>] [[-ManagingCpm] <string>] [[-ConfigPath] <string>] [[-SetDefault] <string>] [-NoPrompt] [-RunDoctor] [-WhatIf] [-Confirm]Description
Section titled “Description”Interactive by default (prompts for anything not supplied). Pass every value plus -NoPrompt for an unattended/scripted setup. Merges into an existing environment.local.json (adds/replaces just the named profile). Nothing secret is written – the OAuth secret is still supplied at runtime. Run Test-HarborSetup afterwards (or pass -RunDoctor).
Examples
Section titled “Examples”Example 1
Section titled “Example 1”Initialize-HarborConfigExample 2
Section titled “Example 2”Initialize-HarborConfig -ProfileName prod -TenantName contoso -TenantId ABC1234 ` -OAuthClientId svc@cyberark.cloud.NNNN -NoPromptExample 3
Section titled “Example 3”# Self-hosted / non-standard URLs: pass them explicitly (overrides the tenant derivation)Initialize-HarborConfig -PvwaUrl https://pvwa.corp/PasswordVault -IdentityUrl https://id.corp -OAuthClientId svc -NoPromptParameters
Section titled “Parameters”-ConfigPath
Section titled “-ConfigPath”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 7 | No |
-Confirm
Section titled “-Confirm”Asks for confirmation before the command changes anything.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
SwitchParameter |
No | Named | No |
Aliases: cf.
-IdentityUrl
Section titled “-IdentityUrl”Advanced override (self-hosted / non-standard)
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 4 | No |
-ManagingCpm
Section titled “-ManagingCpm”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 6 | No |
Default: PasswordManager.
-NoPrompt
Section titled “-NoPrompt”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
SwitchParameter |
No | Named | No |
-OAuthClientId
Section titled “-OAuthClientId”Advanced override
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 5 | No |
-ProfileName
Section titled “-ProfileName”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 0 | No |
Default: prod.
-PvwaUrl
Section titled “-PvwaUrl”E.g. ‘ABC1234’ -> Identity URL
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 3 | No |
-RunDoctor
Section titled “-RunDoctor”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
SwitchParameter |
No | Named | No |
-SetDefault
Section titled “-SetDefault”When does this profile become the suite DEFAULT (the profile a plain launch boots)? IfUnset (CLI default, as before: only when no default exists yet) / Always (the operator ticked “make this the default”) / Never (the console’s tenant save unless asked – it used to switch the suite’s default silently).
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 8 | No |
Accepted values: IfUnset, Always, Never. Default: IfUnset.
-TenantId
Section titled “-TenantId”Subdomain, e.g. ‘contoso’ -> PVWA URL
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 2 | No |
-TenantName
Section titled “-TenantName”Not described in the module help.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
String |
No | 1 | No |
-WhatIf
Section titled “-WhatIf”Shows what the command would do, without doing it.
| Type | Required | Position | Pipeline input |
|---|---|---|---|
SwitchParameter |
No | Named | No |
Aliases: wi.
This command also accepts the PowerShell common parameters (-Verbose, -ErrorAction, and so on).
See also
Section titled “See also”- All Harbor Onboard cmdlets
- In PowerShell:
Get-Help Initialize-HarborConfig -Full
Covers Harbor Onboard 0.59.0 / Harbor Health 0.22.0. On an older release? Upgrading and the release notes list what changed.
