Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions .github/workflows/Codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
#
# https://github.com/microsoft/action-psscriptanalyzer
# For more information on PSScriptAnalyzer in general, see
# https://github.com/PowerShell/PSScriptAnalyzer

name: CodeQL

on:
push:
branches: [ "dev" ]
pull_request:
branches: [ "dev" ]

permissions:
contents: read

jobs:
build:
permissions:
contents: read # for actions/checkout to fetch code
security-events: write # for github/codeql-action/upload-sarif to upload SARIF results
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
name: PSScriptAnalyzer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Run PSScriptAnalyzer
uses: microsoft/psscriptanalyzer-action@v1.1
with:
# Check https://github.com/microsoft/action-psscriptanalyzer for more info about the options.
# The below set up runs PSScriptAnalyzer to your entire repository and runs some basic security rules.
path: .\
recurse: true
# Include your own basic security rules. Removing this option will run all the rules
excludeRule: '"PSAvoidUsingPlainTextForPassword", "PSAvoidUsingUsernameAndPasswordParams", "PSAvoidUsingConvertToSecureStringWithPlainText"'
output: results.sarif

# Upload the SARIF file generated in the previous step
- name: Upload SARIF results file
uses: github/codeql-action/upload-sarif@v2
with:
sarif_file: results.sarif
2 changes: 1 addition & 1 deletion .github/workflows/PSScriptAnalyzer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ jobs:
name: Run PSScriptAnalyzer
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v5
- name: lint
uses: devblackops/github-action-psscriptanalyzer@master
with:
Expand Down
20 changes: 19 additions & 1 deletion .github/workflows/PSScriptAnalyzerSettings.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,24 @@
'PSUseToExportFieldsInManifest',
'PSReviewUnusedParameter',
'PSUseDeclaredVarsMoreThanAssignments',
'PSAvoidGlobalVars'
'PSAvoidGlobalVars',
'PSAvoidUsingWriteHost'
)
Rules = @{
PSAvoidExclaimOperator = @{
Enable = $true
}
AvoidUsingDoubleQuotesForConstantString = @{
Enable = $true
}
UseCorrectCasing = @{
Enable = $true
}
PSAvoidUsingCmdletAliases = @{
Enable = $true
}
PSUseConsistentWhitespace = @{
Enable = $true
}
}
}
62 changes: 62 additions & 0 deletions .github/workflows/Release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Publish PowerShell Module

on:
release:
types: [published]

jobs:
publish-to-gallery:
runs-on: windows-latest
steps:
- uses: actions/checkout@v5
- name: Set PSRepository to Trusted for PowerShell Gallery
shell: pwsh
run: |
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
- name: Install AsBuiltReport.Core module
shell: pwsh
run: |
Install-Module -Name AsBuiltReport.Core -Repository PSGallery -Force
- name: Install PScriboCharts module
shell: pwsh
run: |
Install-Module -Name PScriboCharts -Repository PSGallery -Force
- name: Install Diagrammer.Core module
shell: pwsh
run: |
Install-Module -Name Diagrammer.Core -Repository PSGallery -Force
- name: Test Module Manifest
shell: pwsh
run: |
Test-ModuleManifest .\AsBuiltReport.Veeam.VBR.psd1
- name: Publish module to PowerShell Gallery
shell: pwsh
run: |
Publish-Module -Path ./ -NuGetApiKey ${{ secrets.PSGALLERY_API_KEY }} -Verbose

tweet:
needs: publish-to-gallery
runs-on: ubuntu-latest
steps:
- uses: Eomm/why-don-t-you-tweet@v2
# We don't want to tweet if the repository is not a public one
if: ${{ !github.event.repository.private }}
with:
# GitHub event payload
# https://docs.github.com/en/developers/webhooks-and-events/webhooks/webhook-events-and-payloads#release
tweet-message: "[New Release] ${{ github.event.repository.name }} ${{ github.event.release.tag_name }}! Check out what's new! ${{ github.event.release.html_url }} #Microsoft #SCVMM #AsBuiltReport #PowerShell #MicrosoftMVP #MVPBuzz"
env:
TWITTER_CONSUMER_API_KEY: ${{ secrets.TWITTER_CONSUMER_API_KEY }}
TWITTER_CONSUMER_API_SECRET: ${{ secrets.TWITTER_CONSUMER_API_SECRET }}
TWITTER_ACCESS_TOKEN: ${{ secrets.TWITTER_ACCESS_TOKEN }}
TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }}
bsky-post:
needs: publish-to-gallery
runs-on: ubuntu-latest
steps:
- uses: zentered/bluesky-post-action@v0.2.0
with:
post: "[New Release] ${{ github.event.repository.name }} ${{ github.event.release.tag_name }}! Check out what's new! ${{ github.event.release.html_url }} #Microsoft #SCVMM #AsBuiltReport #PowerShell #MicrosoftMVP #MVPBuzz"
env:
BSKY_IDENTIFIER: ${{ secrets.BSKY_IDENTIFIER }}
BSKY_PASSWORD: ${{ secrets.BSKY_PASSWORD }}
18 changes: 18 additions & 0 deletions .github/workflows/Stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: 'Close stale issues and PRs'
on:
schedule:
- cron: '30 1 * * *'

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
stale-issue-message: 'This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.'
days-before-stale: 30
days-before-close: 7
exempt-pr-labels: 'help wanted,enhancement,security,pinned'
stale-pr-label: 'wontfix'
stale-issue-label: 'wontfix'
exempt-issue-labels: 'help wanted,enhancement,security,pinned'
31 changes: 26 additions & 5 deletions AsBuiltReport.Microsoft.SCVMM.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,34 @@
"ShowTableCaptions": true
},
"Options": {

"VmmServerPort": 8100,
"EnableDiagrams": true,
"EnableDiagramDebug": true,
"DiagramTheme": "White",
"DiagramWaterMark": "Acme Corporation",
"ExportDiagrams": true,
"ExportDiagramsFormat": [
"png"
],
"EnableDiagramSignature": false,
"DiagramColumnSize": 4,
"SignatureAuthorName": "Jonathan Colon",
"SignatureCompanyName": "Zen PR Solutions"
},
"InfoLevel": {
"_comment_": "Please refer to the AsBuiltReport project contributing guide for information about how to define InfoLevels.",
"_comment_": "0 = Disabled, 1 = Enabled / Summary, 2 = Adv Summary, 3 = Detailed, 4 = Adv Detailed, 5 = Comprehensive"
"_comment_": "Please refer to the AsBuiltReport project contributing guide for information about how to define InfoLevels.",
"_comment_": "0 = Disabled, 1 = Enabled / Summary, 2 = Adv Summary, 3 = Detailed, 4 = Adv Detailed, 5 = Comprehensive",
"Infrastructure": 2,
"Networking": 2,
"LibraryTemplates": 2,
"Clusters": 2,
"Hosts": 2
},
"HealthCheck": {

"VMMServer": true,
"Database": true,
"AutoNetwork": true,
"Clusters": true,
"Hosts": true
}
}
}
145 changes: 77 additions & 68 deletions AsBuiltReport.Microsoft.SCVMM.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -8,99 +8,108 @@

@{

# Script module or binary module file associated with this manifest.
RootModule = 'AsBuiltReport.Microsoft.SCVMM.psm1'
# Script module or binary module file associated with this manifest.
RootModule = 'AsBuiltReport.Microsoft.SCVMM.psm1'

# Version number of this module.
ModuleVersion = '0.1.0'
# Version number of this module.
ModuleVersion = '0.1.1'

# Supported PSEditions
# CompatiblePSEditions = @()
# Supported PSEditions
# CompatiblePSEditions = @()

# ID used to uniquely identify this module
GUID = 'b4a72506-7a52-40c6-8649-050db73f2ab7'
# ID used to uniquely identify this module
GUID = 'b4a72506-7a52-40c6-8649-050db73f2ab7'

# Author of this module
Author = 'Andrew Ramsay'
# Author of this module
Author = 'Andrew Ramsay'

# Company or vendor of this module
# CompanyName = 'Unknown'
# Company or vendor of this module
# CompanyName = 'Unknown'

# Copyright statement for this module
Copyright = '(c) 2021 Andrew Ramsay. All rights reserved.'
# Copyright statement for this module
Copyright = '(c) 2025 Andrew Ramsay. All rights reserved.'

# Description of the functionality provided by this module
Description = 'A PowerShell module to generate an as built report on the configuration of Microsoft SCVMM.'
# Description of the functionality provided by this module
Description = 'A PowerShell module to generate an as built report on the configuration of Microsoft SCVMM.'

# Minimum version of the Windows PowerShell engine required by this module
PowerShellVersion = '5.1'
# Minimum version of the Windows PowerShell engine required by this module
PowerShellVersion = '5.1'

# Name of the Windows PowerShell host required by this module
# PowerShellHostName = ''
# Name of the Windows PowerShell host required by this module
# PowerShellHostName = ''

# Minimum version of the Windows PowerShell host required by this module
# PowerShellHostVersion = ''
# Minimum version of the Windows PowerShell host required by this module
# PowerShellHostVersion = ''

# Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# DotNetFrameworkVersion = ''
# Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# DotNetFrameworkVersion = ''

# Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# CLRVersion = ''
# Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only.
# CLRVersion = ''

# Processor architecture (None, X86, Amd64) required by this module
# ProcessorArchitecture = ''
# Processor architecture (None, X86, Amd64) required by this module
# ProcessorArchitecture = ''

# Modules that must be imported into the global environment prior to importing this module
RequiredModules = @(
@{
ModuleName = 'AsBuiltReport.Core';
ModuleVersion = '1.1.0'
}
)
# Modules that must be imported into the global environment prior to importing this module
RequiredModules = @(
@{
ModuleName = 'AsBuiltReport.Core';
ModuleVersion = '1.4.3'
},
@{
ModuleName = 'Diagrammer.Core';
ModuleVersion = '0.2.29'
},
@{
ModuleName = 'PScriboCharts';
ModuleVersion = '0.9.0'
}

# Assemblies that must be loaded prior to importing this module
# RequiredAssemblies = @()
)

# Script files (.ps1) that are run in the caller's environment prior to importing this module.
# ScriptsToProcess = @()
# Assemblies that must be loaded prior to importing this module
# RequiredAssemblies = @()

# Type files (.ps1xml) to be loaded when importing this module
# TypesToProcess = @()
# Script files (.ps1) that are run in the caller's environment prior to importing this module.
# ScriptsToProcess = @()

# Format files (.ps1xml) to be loaded when importing this module
# FormatsToProcess = @()
# Type files (.ps1xml) to be loaded when importing this module
# TypesToProcess = @()

# Modules to import as nested modules of the module specified in RootModule/ModuleToProcess
# NestedModules = @()
# Format files (.ps1xml) to be loaded when importing this module
# FormatsToProcess = @()

# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = @('Invoke-AsBuiltReport.Microsoft.SCVMM')
# Modules to import as nested modules of the module specified in RootModule/ModuleToProcess
# NestedModules = @()

# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
# CmdletsToExport = '*'
# Functions to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no functions to export.
FunctionsToExport = @('Invoke-AsBuiltReport.Microsoft.SCVMM')

# Variables to export from this module
# VariablesToExport = '*'
# Cmdlets to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no cmdlets to export.
# CmdletsToExport = '*'

# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
# AliasesToExport = '*'
# Variables to export from this module
# VariablesToExport = '*'

# DSC resources to export from this module
# DscResourcesToExport = @()
# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
# AliasesToExport = '*'

# List of all modules packaged with this module
# ModuleList = @()
# DSC resources to export from this module
# DscResourcesToExport = @()

# List of all files packaged with this module
# FileList = @()
# List of all modules packaged with this module
# ModuleList = @()

# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{
# List of all files packaged with this module
# FileList = @()

PSData = @{
# Private data to pass to the module specified in RootModule/ModuleToProcess. This may also contain a PSData hashtable with additional module metadata used by PowerShell.
PrivateData = @{

PSData = @{

# Tags applied to this module. These help with module discovery in online galleries.
Tags = 'AsBuiltReport', 'Report', 'Microsoft', 'SCVMM', 'Documentation', 'PScribo', 'Windows', 'Linux', 'MacOS', 'PSEdition_Desktop', 'PSEdition_Core'
Tags = 'AsBuiltReport', 'Report', 'Microsoft', 'SCVMM', 'Documentation', 'PScribo', 'Windows', 'PSEdition_Desktop', 'PSEdition_Core'

# A URL to the license for this module.
LicenseUri = 'https://raw.githubusercontent.com/AsBuiltReport/AsBuiltReport.Microsoft.SCVMM/master/LICENSE'
Expand All @@ -116,13 +125,13 @@ PrivateData = @{

} # End of PSData hashtable

} # End of PrivateData hashtable
} # End of PrivateData hashtable

# HelpInfo URI of this module
# HelpInfoURI = ''
# HelpInfo URI of this module
# HelpInfoURI = ''

# Default prefix for commands exported from this module. Override the default prefix using Import-Module -Prefix.
# DefaultCommandPrefix = ''
# Default prefix for commands exported from this module. Override the default prefix using Import-Module -Prefix.
# DefaultCommandPrefix = ''

}

Expand Down
Loading
Loading