Set the repository notification configuration.


Set-RepositoryNotificationConfiguration [[-Server] <String>] [[-Port] <Int32>] [[-Tls] <String>] [[-Username] <String>] [[-Password] <String>] [[-From] <String>] [[-FromName] <String>] [[-RemoveCredentials]] [<CommonParameters>]


This function defines a notification SMTP server (and optionally, port) for an email server to be used to send failure notifications during unattended synchronization via Invoke-RepositorySync.

One or more recipients can then be added via Add-RepositorySyncFailureRecipient.

The directory must have been initialized via Initialize-Repository.

The function must be invoked inside a directory initialized as a repository.


Name Argument Description
Server <String> The server name (or IP) for the outgoing mail (SMTP) server
Port <Int32> Specifies a port for the SMTP server. If not provided, the default IANA-assigned port 25 will be used.
Tls <String> Specifies whether to use SSL/TLS. The value may be "true", "false", or "auto". "Auto" will automatically set SSL to true when the port is changed to a value different than 25. By default, TLS is false.
Username <String> Specifies the SMTP server username for authenticated SMTP servers. If username is not specified, connection will be made without authentication.
Password <String> Specifies the SMTP server password for authenticated SMTP servers.
From <String> Specifies the email address from which the notification will appear to originate. Note that in servers may accept emails from specified
domains only, or in some cases may require the email address to match the username.
FromName <String> Specifies the from address display name.
RemoveCredentials Removes the SMTP server credentials without removing the entire mail server configuration.


PS C:\> Set-RepositoryNotificationConfiguration

See also