Examples/Resources/xSQLServerReplication/2-ConfigureInstanceAsPublisher.ps1

<#
.EXAMPLE
    This example shows how to configure a SQL Server instance as the publisher.
#>

Configuration Example
{
    param
    (
        [Parameter(Mandatory = $true)]
        [System.Management.Automation.PSCredential]
        [System.Management.Automation.Credential()]
        $SysAdminAccount
    )

    Import-DscResource -ModuleName xSqlServer

    node localhost
    {
        xSQLServerReplication publisher
        {
            Ensure               = 'Present'
            InstanceName         = 'PUBLISHER'
            AdminLinkCredentials = $SysAdminAccount
            DistributorMode      = 'Remote'
            RemoteDistributor    = 'distsqlsrv.company.local'
            WorkingDirectory     = 'C:\Temp'

            PsDscRunAsCredential = $SysAdminAccount
        }
    }
}