Single-File
Single-file hosting and configuration for PowerShell Universal.
Single File Hosting and Configuration
Installing
Install-PSUServer -AddToPathConfiguration
Start-PSUServer -Port 8080 -Configuration {
New-PSUEndpoint -Method GET -Url '/user' -Endpoint { "User1" }
New-PSUEndpoint -Method POST -Url '/user' -Endpoint { $Body }
New-PSUPublishedFolder -Path C:\images -RequestPath /images
New-PSUDashboard -Name 'Dashboard' -BaseUrl '/' -Framework "UniversalDashboard:Latest" -Content {
New-UDDashboard -Title 'Test' -Content {
New-UDTypography -Text 'Hello, world!'
}
}
} -ExecutablePath "$Env:ProgramData\PowerShellUniversal\Universal.Server.exe"Limitations
Referencing Other Files
Last updated
Was this helpful?