* Fixing Interface Type parameter (#42) @SheffSix 

* Fixing #41

* Update `deploy.ps1` to remove trailing whitespaces from psd1

* Increase version to 1.7.3

* Fix location of whitespace cleanup in `deploy.ps1`

---------

Co-authored-by: SheffSix <jbeck1867@gmail.com>
Co-authored-by: Ben Claussen <benclaussen@gmail.com>
This commit is contained in:
Ben Claussen 2023-03-13 09:53:15 -04:00 committed by GitHub
parent 441b06eb04
commit 29dd7ac038
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 93 additions and 76 deletions

View file

@ -10,6 +10,9 @@ function Add-NetboxDCIMInterface {
[Parameter(Mandatory = $true)] [Parameter(Mandatory = $true)]
[string]$Name, [string]$Name,
[ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[bool]$Enabled, [bool]$Enabled,
[object]$Form_Factor, [object]$Form_Factor,

View file

@ -25,7 +25,8 @@ function Get-NetboxDCIMInterface {
[uint16]$Device_Id, [uint16]$Device_Id,
[uint16]$Type, [ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[uint16]$LAG_Id, [uint16]$LAG_Id,

View file

@ -17,6 +17,9 @@ function Set-NetboxDCIMInterface {
[object]$Form_Factor, [object]$Form_Factor,
[ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[uint16]$MTU, [uint16]$MTU,
[string]$MAC_Address, [string]$MAC_Address,

View file

@ -1,9 +1,9 @@
# #
# Module manifest for module 'NetboxPS' # Module manifest for module 'NetboxPS'
# #
# Generated by: Ben Claussen # Generated by: Ben Claussen
# #
# Generated on: 2023-03-10 # Generated on: 2023-03-13
# #
@{ @{
@ -12,7 +12,7 @@
RootModule = 'NetboxPS.psm1' RootModule = 'NetboxPS.psm1'
# Version number of this module. # Version number of this module.
ModuleVersion = '1.7.2' ModuleVersion = '1.7.3'
# Supported PSEditions # Supported PSEditions
# CompatiblePSEditions = @() # CompatiblePSEditions = @()
@ -69,39 +69,39 @@ CLRVersion = '2.0.50727'
NestedModules = @() NestedModules = @()
# 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. # 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 = 'Add-NetboxDCIMInterface', 'Add-NetboxDCIMInterfaceConnection', FunctionsToExport = 'Add-NetboxDCIMInterface', 'Add-NetboxDCIMInterfaceConnection',
'Add-NetboxVirtualMachineInterface', 'Clear-NetboxCredential', 'Add-NetboxVirtualMachineInterface', 'Clear-NetboxCredential',
'Connect-NetboxAPI', 'Get-ModelDefinition', 'Get-NetboxAPIDefinition', 'Connect-NetboxAPI', 'Get-ModelDefinition', 'Get-NetboxAPIDefinition',
'Get-NetboxCircuit', 'Get-NetboxCircuitProvider', 'Get-NetboxCircuit', 'Get-NetboxCircuitProvider',
'Get-NetboxCircuitTermination', 'Get-NetboxCircuitType', 'Get-NetboxCircuitTermination', 'Get-NetboxCircuitType',
'Get-NetboxContact', 'Get-NetboxContactAssignment', 'Get-NetboxContact', 'Get-NetboxContactAssignment',
'Get-NetboxContactRole', 'Get-NetboxContentType', 'Get-NetboxContactRole', 'Get-NetboxContentType',
'Get-NetboxCredential', 'Get-NetboxDCIMDevice', 'Get-NetboxCredential', 'Get-NetboxDCIMDevice',
'Get-NetboxDCIMDeviceRole', 'Get-NetboxDCIMDeviceType', 'Get-NetboxDCIMDeviceRole', 'Get-NetboxDCIMDeviceType',
'Get-NetboxDCIMInterface', 'Get-NetboxDCIMInterfaceConnection', 'Get-NetboxDCIMInterface', 'Get-NetboxDCIMInterfaceConnection',
'Get-NetboxDCIMPlatform', 'Get-NetboxDCIMSite', 'Get-NetboxHostname', 'Get-NetboxDCIMPlatform', 'Get-NetboxDCIMSite', 'Get-NetboxHostname',
'Get-NetboxHostPort', 'Get-NetboxHostScheme', 'Get-NetboxHostPort', 'Get-NetboxHostScheme',
'Get-NetboxInvokeParams', 'Get-NetboxIPAMAddress', 'Get-NetboxInvokeParams', 'Get-NetboxIPAMAddress',
'Get-NetboxIPAMAggregate', 'Get-NetboxIPAMAvailableIP', 'Get-NetboxIPAMAggregate', 'Get-NetboxIPAMAvailableIP',
'Get-NetboxIPAMPrefix', 'Get-NetboxIPAMRole', 'Get-NetboxIPAMVLAN', 'Get-NetboxIPAMPrefix', 'Get-NetboxIPAMRole', 'Get-NetboxIPAMVLAN',
'Get-NetboxTenant', 'Get-NetboxTimeout', 'Get-NetboxVersion', 'Get-NetboxTenant', 'Get-NetboxTimeout', 'Get-NetboxVersion',
'Get-NetboxVirtualizationCluster', 'Get-NetboxVirtualizationCluster',
'Get-NetboxVirtualizationClusterGroup', 'Get-NetboxVirtualMachine', 'Get-NetboxVirtualizationClusterGroup', 'Get-NetboxVirtualMachine',
'Get-NetboxVirtualMachineInterface', 'New-NetboxCircuit', 'Get-NetboxVirtualMachineInterface', 'New-NetboxCircuit',
'New-NetboxContact', 'New-NetboxContactAssignment', 'New-NetboxContact', 'New-NetboxContactAssignment',
'New-NetboxContactRole', 'New-NetboxDCIMDevice', 'New-NetboxDCIMSite', 'New-NetboxContactRole', 'New-NetboxDCIMDevice', 'New-NetboxDCIMSite',
'New-NetboxIPAMAddress', 'New-NetboxIPAMPrefix', 'New-NetboxIPAMVLAN', 'New-NetboxIPAMAddress', 'New-NetboxIPAMPrefix', 'New-NetboxIPAMVLAN',
'New-NetboxTenant', 'New-NetboxVirtualMachine', 'New-NetboxTenant', 'New-NetboxVirtualMachine',
'Remove-NetboxDCIMDevice', 'Remove-NetboxDCIMInterface', 'Remove-NetboxDCIMDevice', 'Remove-NetboxDCIMInterface',
'Remove-NetboxDCIMInterfaceConnection', 'Remove-NetboxDCIMSite', 'Remove-NetboxDCIMInterfaceConnection', 'Remove-NetboxDCIMSite',
'Remove-NetboxIPAMAddress', 'Remove-NetboxVirtualMachine', 'Remove-NetboxIPAMAddress', 'Remove-NetboxVirtualMachine',
'Set-NetboxCipherSSL', 'Set-NetboxContact', 'Set-NetboxCredential', 'Set-NetboxCipherSSL', 'Set-NetboxContact', 'Set-NetboxCredential',
'Set-NetboxDCIMDevice', 'Set-NetboxDCIMInterface', 'Set-NetboxDCIMDevice', 'Set-NetboxDCIMInterface',
'Set-NetboxDCIMInterfaceConnection', 'Set-NetboxHostName', 'Set-NetboxDCIMInterfaceConnection', 'Set-NetboxHostName',
'Set-NetboxHostPort', 'Set-NetboxHostScheme', 'Set-NetboxHostPort', 'Set-NetboxHostScheme',
'Set-NetboxInvokeParams', 'Set-NetboxIPAMAddress', 'Set-NetboxInvokeParams', 'Set-NetboxIPAMAddress',
'Set-NetboxIPAMPrefix', 'Set-NetboxTimeout', 'Set-NetboxIPAMPrefix', 'Set-NetboxTimeout',
'Set-NetboxUnstrustedSSL', 'Set-NetboxVirtualMachine', 'Set-NetboxUnstrustedSSL', 'Set-NetboxVirtualMachine',
'Set-NetboxVirtualMachineInterface', 'Test-NetboxAPIConnected' 'Set-NetboxVirtualMachineInterface', 'Test-NetboxAPIConnected'
# 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. # 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.

View file

@ -1,9 +1,9 @@
# #
# Module manifest for module 'NetboxPS' # Module manifest for module 'NetboxPS'
# #
# Generated by: Ben Claussen # Generated by: Ben Claussen
# #
# Generated on: 2023-03-10 # Generated on: 2023-03-13
# #
@{ @{
@ -12,7 +12,7 @@
RootModule = 'NetboxPS.psm1' RootModule = 'NetboxPS.psm1'
# Version number of this module. # Version number of this module.
ModuleVersion = '1.7.2' ModuleVersion = '1.7.3'
# Supported PSEditions # Supported PSEditions
# CompatiblePSEditions = @() # CompatiblePSEditions = @()
@ -69,39 +69,39 @@ CLRVersion = '2.0.50727'
NestedModules = @() NestedModules = @()
# 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. # 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 = 'Add-NetboxDCIMInterface', 'Add-NetboxDCIMInterfaceConnection', FunctionsToExport = 'Add-NetboxDCIMInterface', 'Add-NetboxDCIMInterfaceConnection',
'Add-NetboxVirtualMachineInterface', 'Clear-NetboxCredential', 'Add-NetboxVirtualMachineInterface', 'Clear-NetboxCredential',
'Connect-NetboxAPI', 'Get-ModelDefinition', 'Get-NetboxAPIDefinition', 'Connect-NetboxAPI', 'Get-ModelDefinition', 'Get-NetboxAPIDefinition',
'Get-NetboxCircuit', 'Get-NetboxCircuitProvider', 'Get-NetboxCircuit', 'Get-NetboxCircuitProvider',
'Get-NetboxCircuitTermination', 'Get-NetboxCircuitType', 'Get-NetboxCircuitTermination', 'Get-NetboxCircuitType',
'Get-NetboxContact', 'Get-NetboxContactAssignment', 'Get-NetboxContact', 'Get-NetboxContactAssignment',
'Get-NetboxContactRole', 'Get-NetboxContentType', 'Get-NetboxContactRole', 'Get-NetboxContentType',
'Get-NetboxCredential', 'Get-NetboxDCIMDevice', 'Get-NetboxCredential', 'Get-NetboxDCIMDevice',
'Get-NetboxDCIMDeviceRole', 'Get-NetboxDCIMDeviceType', 'Get-NetboxDCIMDeviceRole', 'Get-NetboxDCIMDeviceType',
'Get-NetboxDCIMInterface', 'Get-NetboxDCIMInterfaceConnection', 'Get-NetboxDCIMInterface', 'Get-NetboxDCIMInterfaceConnection',
'Get-NetboxDCIMPlatform', 'Get-NetboxDCIMSite', 'Get-NetboxHostname', 'Get-NetboxDCIMPlatform', 'Get-NetboxDCIMSite', 'Get-NetboxHostname',
'Get-NetboxHostPort', 'Get-NetboxHostScheme', 'Get-NetboxHostPort', 'Get-NetboxHostScheme',
'Get-NetboxInvokeParams', 'Get-NetboxIPAMAddress', 'Get-NetboxInvokeParams', 'Get-NetboxIPAMAddress',
'Get-NetboxIPAMAggregate', 'Get-NetboxIPAMAvailableIP', 'Get-NetboxIPAMAggregate', 'Get-NetboxIPAMAvailableIP',
'Get-NetboxIPAMPrefix', 'Get-NetboxIPAMRole', 'Get-NetboxIPAMVLAN', 'Get-NetboxIPAMPrefix', 'Get-NetboxIPAMRole', 'Get-NetboxIPAMVLAN',
'Get-NetboxTenant', 'Get-NetboxTimeout', 'Get-NetboxVersion', 'Get-NetboxTenant', 'Get-NetboxTimeout', 'Get-NetboxVersion',
'Get-NetboxVirtualizationCluster', 'Get-NetboxVirtualizationCluster',
'Get-NetboxVirtualizationClusterGroup', 'Get-NetboxVirtualMachine', 'Get-NetboxVirtualizationClusterGroup', 'Get-NetboxVirtualMachine',
'Get-NetboxVirtualMachineInterface', 'New-NetboxCircuit', 'Get-NetboxVirtualMachineInterface', 'New-NetboxCircuit',
'New-NetboxContact', 'New-NetboxContactAssignment', 'New-NetboxContact', 'New-NetboxContactAssignment',
'New-NetboxContactRole', 'New-NetboxDCIMDevice', 'New-NetboxDCIMSite', 'New-NetboxContactRole', 'New-NetboxDCIMDevice', 'New-NetboxDCIMSite',
'New-NetboxIPAMAddress', 'New-NetboxIPAMPrefix', 'New-NetboxIPAMVLAN', 'New-NetboxIPAMAddress', 'New-NetboxIPAMPrefix', 'New-NetboxIPAMVLAN',
'New-NetboxTenant', 'New-NetboxVirtualMachine', 'New-NetboxTenant', 'New-NetboxVirtualMachine',
'Remove-NetboxDCIMDevice', 'Remove-NetboxDCIMInterface', 'Remove-NetboxDCIMDevice', 'Remove-NetboxDCIMInterface',
'Remove-NetboxDCIMInterfaceConnection', 'Remove-NetboxDCIMSite', 'Remove-NetboxDCIMInterfaceConnection', 'Remove-NetboxDCIMSite',
'Remove-NetboxIPAMAddress', 'Remove-NetboxVirtualMachine', 'Remove-NetboxIPAMAddress', 'Remove-NetboxVirtualMachine',
'Set-NetboxCipherSSL', 'Set-NetboxContact', 'Set-NetboxCredential', 'Set-NetboxCipherSSL', 'Set-NetboxContact', 'Set-NetboxCredential',
'Set-NetboxDCIMDevice', 'Set-NetboxDCIMInterface', 'Set-NetboxDCIMDevice', 'Set-NetboxDCIMInterface',
'Set-NetboxDCIMInterfaceConnection', 'Set-NetboxHostName', 'Set-NetboxDCIMInterfaceConnection', 'Set-NetboxHostName',
'Set-NetboxHostPort', 'Set-NetboxHostScheme', 'Set-NetboxHostPort', 'Set-NetboxHostScheme',
'Set-NetboxInvokeParams', 'Set-NetboxIPAMAddress', 'Set-NetboxInvokeParams', 'Set-NetboxIPAMAddress',
'Set-NetboxIPAMPrefix', 'Set-NetboxTimeout', 'Set-NetboxIPAMPrefix', 'Set-NetboxTimeout',
'Set-NetboxUnstrustedSSL', 'Set-NetboxVirtualMachine', 'Set-NetboxUnstrustedSSL', 'Set-NetboxVirtualMachine',
'Set-NetboxVirtualMachineInterface', 'Test-NetboxAPIConnected' 'Set-NetboxVirtualMachineInterface', 'Test-NetboxAPIConnected'
# 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. # 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.

View file

@ -14,6 +14,9 @@ function Add-NetboxDCIMInterface {
[Parameter(Mandatory = $true)] [Parameter(Mandatory = $true)]
[string]$Name, [string]$Name,
[ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[bool]$Enabled, [bool]$Enabled,
[object]$Form_Factor, [object]$Form_Factor,
@ -1637,7 +1640,8 @@ function Get-NetboxDCIMInterface {
[uint16]$Device_Id, [uint16]$Device_Id,
[uint16]$Type, [ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[uint16]$LAG_Id, [uint16]$LAG_Id,
@ -4698,6 +4702,9 @@ function Set-NetboxDCIMInterface {
[object]$Form_Factor, [object]$Form_Factor,
[ValidateSet('virtual', 'bridge', 'lag', '100base-tx', '1000base-t', '2.5gbase-t', '5gbase-t', '10gbase-t', '10gbase-cx4', '1000base-x-gbic', '1000base-x-sfp', '10gbase-x-sfpp', '10gbase-x-xfp', '10gbase-x-xenpak', '10gbase-x-x2', '25gbase-x-sfp28', '50gbase-x-sfp56', '40gbase-x-qsfpp', '50gbase-x-sfp28', '100gbase-x-cfp', '100gbase-x-cfp2', '200gbase-x-cfp2', '100gbase-x-cfp4', '100gbase-x-cpak', '100gbase-x-qsfp28', '200gbase-x-qsfp56', '400gbase-x-qsfpdd', '400gbase-x-osfp', '1000base-kx', '10gbase-kr', '10gbase-kx4', '25gbase-kr', '40gbase-kr4', '50gbase-kr', '100gbase-kp4', '100gbase-kr2', '100gbase-kr4', 'ieee802.11a', 'ieee802.11g', 'ieee802.11n', 'ieee802.11ac', 'ieee802.11ad', 'ieee802.11ax', 'ieee802.11ay', 'ieee802.15.1', 'other-wireless', 'gsm', 'cdma', 'lte', 'sonet-oc3', 'sonet-oc12', 'sonet-oc48', 'sonet-oc192', 'sonet-oc768', 'sonet-oc1920', 'sonet-oc3840', '1gfc-sfp', '2gfc-sfp', '4gfc-sfp', '8gfc-sfpp', '16gfc-sfpp', '32gfc-sfp28', '64gfc-qsfpp', '128gfc-qsfp28', 'infiniband-sdr', 'infiniband-ddr', 'infiniband-qdr', 'infiniband-fdr10', 'infiniband-fdr', 'infiniband-edr', 'infiniband-hdr', 'infiniband-ndr', 'infiniband-xdr', 't1', 'e1', 't3', 'e3', 'xdsl', 'docsis', 'gpon', 'xg-pon', 'xgs-pon', 'ng-pon2', 'epon', '10g-epon', 'cisco-stackwise', 'cisco-stackwise-plus', 'cisco-flexstack', 'cisco-flexstack-plus', 'cisco-stackwise-80', 'cisco-stackwise-160', 'cisco-stackwise-320', 'cisco-stackwise-480', 'juniper-vcp', 'extreme-summitstack', 'extreme-summitstack-128', 'extreme-summitstack-256', 'extreme-summitstack-512', 'other', IgnoreCase = $true)]
[string]$Type,
[uint16]$MTU, [uint16]$MTU,
[string]$MAC_Address, [string]$MAC_Address,

View file

@ -64,6 +64,7 @@ $FunctionPath = "$PSScriptRoot\Functions"
$OutputDirectory = "$PSScriptRoot\$ModuleName" $OutputDirectory = "$PSScriptRoot\$ModuleName"
$PSD1OutputPath = "$OutputDirectory\$ModuleName.psd1" $PSD1OutputPath = "$OutputDirectory\$ModuleName.psd1"
$PSM1OutputPath = "$OutputDirectory\$ModuleName.psm1" $PSM1OutputPath = "$OutputDirectory\$ModuleName.psm1"
$PS1FunctionFiles = Get-ChildItem $FunctionPath -Filter "*.ps1" -Recurse | Sort-Object Name
Write-Host "Removing whitespace from files" -ForegroundColor Green Write-Host "Removing whitespace from files" -ForegroundColor Green
@ -71,7 +72,6 @@ Invoke-ScriptAnalyzer -Path $FunctionPath -IncludeRule 'PSAvoidTrailingWhitespac
Write-Host "Concatenating [$($PS1FunctionFiles.Count)] PS1 files from $FunctionPath" Write-Host "Concatenating [$($PS1FunctionFiles.Count)] PS1 files from $FunctionPath"
$PS1FunctionFiles = Get-ChildItem $FunctionPath -Filter "*.ps1" -Recurse | Sort-Object Name
"" | Out-File -FilePath $ConcatenatedFilePath -Encoding utf8 "" | Out-File -FilePath $ConcatenatedFilePath -Encoding utf8
@ -152,6 +152,10 @@ switch ($PSCmdlet.ParameterSetName) {
Write-Host "Updating Module Manifest" Write-Host "Updating Module Manifest"
Update-ModuleManifest @UpdateModuleManifestSplat Update-ModuleManifest @UpdateModuleManifestSplat
Write-Host " Removing trailing whitespaces from psd1"
Invoke-ScriptAnalyzer -Path $UpdateModuleManifestSplat.Path -IncludeRule 'PSAvoidTrailingWhitespace' -Fix
if (-not (Test-Path $OutputDirectory)) { if (-not (Test-Path $OutputDirectory)) {
try { try {
Write-Warning "Creating output directory [$OutputDirectory]" Write-Warning "Creating output directory [$OutputDirectory]"
@ -165,7 +169,6 @@ if (-not (Test-Path $OutputDirectory)) {
Write-Host " Copying psd1" Write-Host " Copying psd1"
Copy-Item -Path "$PSScriptRoot\$ModuleName.psd1" -Destination $PSD1OutputPath -Force Copy-Item -Path "$PSScriptRoot\$ModuleName.psd1" -Destination $PSD1OutputPath -Force
Write-Host " Copying psm1" Write-Host " Copying psm1"
Copy-Item -Path $ConcatenatedFilePath -Destination $PSM1OutputPath -Force Copy-Item -Path $ConcatenatedFilePath -Destination $PSM1OutputPath -Force