You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A PowerShell module for managing VergeOS infrastructure. PSVergeOS provides a comprehensive set of cmdlets for automating VM lifecycle, networking, storage, multi-tenant operations, and disaster recovery through the VergeOS REST API.
Built for infrastructure administrators and automation engineers who want to leverage PowerShell expertise for VergeOS management.
Key Features
Complete VM Management - Create, configure, start, stop, clone, snapshot, and migrate virtual machines
NAS & Storage - Manage NAS services, volumes, CIFS/NFS shares, and volume synchronization
Multi-Tenancy - Provision and manage tenant environments with full resource isolation
Disaster Recovery - Cloud snapshots, site synchronization, and automated recovery workflows
Pipeline Support - Chain cmdlets together for bulk operations and automation
Cross-Platform - Works on Windows, macOS, and Linux with PowerShell 7.4+
Requirements
PowerShell 7.4 or later
VergeOS 26.0 or later
Installation
From PowerShell Gallery (Recommended)
Install-Module-Name PSVergeOS -Scope CurrentUser
Manual Installation
# Clone the repository
git clone https://github.com/verge-io/PSVergeOS.git
# Import the moduleImport-Module ./PSVergeOS/PSVergeOS.psd1
Quick Start
Connect to VergeOS
# Interactive login with credential promptConnect-VergeOS-Server "vergeos.company.com"-Credential (Get-Credential)
# Token-based login for automationConnect-VergeOS-Server "vergeos.company.com"-Token $env:VERGE_TOKEN# Self-signed certificate environmentsConnect-VergeOS-Server "vergeos.local"-Credential $cred-SkipCertificateCheck
Virtual Machine Operations
# List all VMsGet-VergeVM# Filter VMs by name and stateGet-VergeVM-Name "Web*"-PowerState Running
# Start/Stop VMsStart-VergeVM-Name "WebServer01"Stop-VergeVM-Name "WebServer01"# Create a snapshot before maintenanceNew-VergeVMSnapshot-VMName "WebServer01"-Name "Pre-Update"# Clone a VM from templateNew-VergeVMClone-SourceVM "Template-Ubuntu22"-Name "NewServer"
Network Management
# Create a network with DHCPNew-VergeNetwork-Name "App-Network"-NetworkAddress "10.10.0.0/24"`-Gateway "10.10.0.1"-DHCPEnabled -DHCPStart "10.10.0.100"-DHCPStop "10.10.0.200"# Add a firewall ruleNew-VergeNetworkRule-Network "External"-Name "Allow-HTTPS"`-Action Accept -Direction Incoming -Protocol TCP -DestinationPorts "443"# Apply rules to activate changesInvoke-VergeNetworkApply-Network "External"
Bulk Operations with Pipeline
# Stop all VMs matching a patternGet-VergeVM-Name "Dev-*"|Stop-VergeVM-Confirm:$false# Snapshot all production VMsGet-VergeVM-Name "Prod-*"|ForEach-Object {
New-VergeVMSnapshot-VMName $_.Name-Name "Daily-$(Get-Date-Format 'yyyyMMdd')"
}
# Export VM inventory to CSVGet-VergeVM|Select-Object Name, PowerState, CPUCores, RAM, Cluster |Export-Csv vms.csv
Webhook integration: Slack/Teams notifications, API callbacks, delivery history
Development
Running Tests
# Run all testsInvoke-Pester-Path ./Tests
# Run with code coverageInvoke-Pester-Path ./Tests -CodeCoverage ./Public/**/*.ps1
# Run specific test fileInvoke-Pester-Path ./Tests/Unit/Connection.Tests.ps1
Code Quality
# Analyze code with PSScriptAnalyzerInvoke-ScriptAnalyzer-Path ./Public -Recurse
Local Development
# Import module for testingImport-Module ./PSVergeOS.psd1 -Force
# List all available cmdletsGet-Command-Module PSVergeOS
Contributing
Contributions are welcome! Please follow these guidelines:
Fork the repository
Create a feature branch (git checkout -b feature/new-cmdlet)
Write tests for your changes
Ensure all tests pass (Invoke-Pester)
Run script analyzer (Invoke-ScriptAnalyzer)
Submit a pull request
License
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
PowerShell module for VergeOS infrastructure automation. 200+ cmdlets for VM lifecycle, networking, storage, multi-tenancy, and disaster recovery via the REST API.