New-DSVirtualGateway

Synopsis

Create a virtual gateway.

Syntax

__AllParameterSets

New-DSVirtualGateway [-LinkedGatewayID] <guid> [-Name] <string> [[-Description] <string>]
 [[-Rule] <PSGatewayAccessRule[]>] [-IsDefault] [<CommonParameters>]

Description

Create a virtual gateway. It must be linked to an existing gateway. The rules to allow or deny access must be created with the cmdlet New-DSVirtualGatewayAccessRule.

Examples

Example 1

PS C:\> $rules = @(
    New-DSVirtualGatewayAccessRule -Access Deny -Type IP -Value '1.2.3.4'
    New-DSVirtualGatewayAccessRule -Access Deny -Type DNS 'a.com'
  )
PS C:\> $gatewayId = Get-DSGateway -Name 'GatewayA' | Select-Object -ExpandProperty ID
PS C:\> New-DSVirtualGateway -LinkedGatewayID $gatewayId -Name 'My virtual gateway' -Description 'A little description' -Rule $rules

Create a virtual gateway that denies access from a specific IP address and the domain 'a.com'.

Parameters

-Description

Description of the virtual gateway.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 2
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-IsDefault

Set the virtual gateway as the default gateway.

Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: Named
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-LinkedGatewayID

Physical gateway's ID.

Type: System.Nullable`1[System.Guid]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 0
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Name

Name of the virtual gateway.

Type: System.String
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 1
  IsRequired: true
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

-Rule

Rules of the virtual gateway to allow or deny access.

Type: Devolutions.PowerShell.PSOutputObject.PSGatewayAccessRule[]
DefaultValue: ''
SupportsWildcards: false
Aliases: []
ParameterSets:
- Name: (All)
  Position: 3
  IsRequired: false
  ValueFromPipeline: false
  ValueFromPipelineByPropertyName: false
  ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Notes

For more information, type "Get-Help New-DSVirtualGateway -detailed". For technical information, type "Get-Help New-DSVirtualGateway -full".

Devolutions Forum logo Partagez vos commentaires