mirror of
https://github.com/GoodOlClint/PSProxmoxVE.git
synced 2026-09-06 12:09:01 +00:00
0026ef2b57
NodeService.GetNodeConfig/GetNodeDns, ClusterConfigService.GetClusterConfig, BackupService.GetNotBackedUp and VmService.GetGuestExecStatus returned raw Dictionary/List<Dictionary> instead of a Pve* model, per issue #157. Each now has a typed model under Models/{Nodes,Cluster,Backup,Vms}/ with [JsonProperty] for documented fields and a [JsonExtensionData]-backed AdditionalProperties catch-all, following the PveVmConfig pattern. The five consuming cmdlets and their [OutputType] attributes are updated to match. GetClusterConfig also fixes a latent bug: GET /cluster/config returns a JSON array (a directory index), but the old code did `data is JObject obj ? ... : empty dict`, which silently always returned an empty dictionary since data was a JArray. PveClusterConfigEntry decodes the array correctly and exposes a typed Name property (the array items' schema documents no named fields, but the endpoint's "links" metadata gives the child-URL template as "{name}"). The guest-exec poll loop in InvokePveVmGuestExecCmdlet keeps its exact Stopwatch + Thread.Sleep(1000) structure (ADR 0001 accepted exception); only the type it reads from changed. A TolerantBooleanConverter was added so PveGuestExecStatus.Exited keeps accepting PVE's boolean/integer/string forms, matching what ApiValueHelper.IsExited already tolerated for the old dictionary path. Reviewed with codex-rescue, correctness-reviewer and api-compat-reviewer before commit; both real findings above (the name/subdir key and the Exited string-form regression) came from that pass and are mutation-tested. Co-authored-by: goodolclint-claude[bot] <323206664+goodolclint-claude[bot]@users.noreply.github.com>
91 lines
1.7 KiB
Markdown
91 lines
1.7 KiB
Markdown
---
|
|
external help file: PSProxmoxVE.dll-Help.xml
|
|
Module Name: PSProxmoxVE
|
|
online version:
|
|
schema: 2.0.0
|
|
---
|
|
|
|
# Get-PveNodeConfig
|
|
|
|
## SYNOPSIS
|
|
Returns the configuration of a Proxmox VE node.
|
|
|
|
## SYNTAX
|
|
|
|
```
|
|
Get-PveNodeConfig [-Node] <String> [-Session <PveSession>] [-ProgressAction <ActionPreference>]
|
|
[<CommonParameters>]
|
|
```
|
|
|
|
## DESCRIPTION
|
|
Retrieves the node configuration from the /nodes/{node}/config endpoint, including description, wakeonlan settings and other node-level properties.
|
|
|
|
## EXAMPLES
|
|
|
|
### Example 1
|
|
```powershell
|
|
PS C:\> Get-PveNodeConfig -Node "pve1"
|
|
```
|
|
|
|
Returns the configuration for node pve1.
|
|
|
|
## PARAMETERS
|
|
|
|
### -Node
|
|
The PVE node name.
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: True
|
|
Position: 0
|
|
Default value: None
|
|
Accept pipeline input: True (ByPropertyName)
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Session
|
|
{{ Fill Session Description }}
|
|
|
|
```yaml
|
|
Type: PveSession
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -ProgressAction
|
|
{{ Fill ProgressAction Description }}
|
|
|
|
```yaml
|
|
Type: ActionPreference
|
|
Parameter Sets: (All)
|
|
Aliases: proga
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### CommonParameters
|
|
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
|
|
|
## INPUTS
|
|
|
|
### System.String
|
|
## OUTPUTS
|
|
|
|
### PSProxmoxVE.Core.Models.Nodes.PveNodeConfig
|
|
## NOTES
|
|
|
|
## RELATED LINKS
|