Active Directory Management Framework

Configuration driven Active Directory management.

Set-AdcRemotingConfig

SYNOPSIS

Define the connection settings to use for PS remoting connections to the target.

SYNTAX

Set-AdcRemotingConfig [-Target] <String> [[-Parameters] <Hashtable>] [[-SessionOption] <PSSessionOption>]
 [-UseSSH] [[-SshUserName] <String>] [[-SshKeyFilePath] <String>] [[-SshSubsystem] <String>] [-SshTransport]
 [[-SshOption] <Hashtable>] [-ProgressAction <ActionPreference>] [<CommonParameters>]

DESCRIPTION

Define the connection settings to use for PS remoting connections to the target. Target can be any specific host, domain or subdomain.

For example, assuming these three targets have settings defined:

In this case, the most specific target wins:

EXAMPLES

EXAMPLE 1

Set-AdcRemotingConfig -Target contoso.com -SessionOption $option

Have all remoting connections to DCs in contoso.com use the specified options.

EXAMPLE 2

Set-AdcRemotingConfig -Target dc1.contoso.com -UseSSH

Have all remoting connections to DC dc1.contoso.com use SSH.

PARAMETERS

-Target

The target the configuration applies to.

Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Parameters

Parameters to use when establishing the connection. Each key in the hashtable must map to a parameter on “New-PSSession”. Note: There are different parameters between PowerShell v5.1 and v7+.

Type: Hashtable
Parameter Sets: (All)
Aliases:

Required: False
Position: 2
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SessionOption

A PowerShell session option item to apply. This allows enabling proxy settings and other connection metadata.

Type: PSSessionOption
Parameter Sets: (All)
Aliases:

Required: False
Position: 3
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-UseSSH

Use SSH for the remoting connection. Redundant if used with other SSH parameters.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-SshUserName

The user name to use with SSH sessions.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 4
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SshKeyFilePath

The path to the key file for authenticating via SSH.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 5
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SshSubsystem

The Subsystem in the SSH server.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 6
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-SshTransport

Whether to use SSH transport.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False

-SshOption

The SSH options to include.

Type: Hashtable
Parameter Sets: (All)
Aliases:

Required: False
Position: 7
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ProgressAction

Type: ActionPreference
Parameter Sets: (All)
Aliases: proga

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

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

INPUTS

OUTPUTS

NOTES