The Active Directory connector is a small Windows service that runs on your network, reads identity data from AD on Ploy's behalf, and optionally writes group membership changes back. AD credentials never leave your network; all connections are initiated outbound from the connector to https://api.joinploy.com.
What you need before you start
A domain-joined Windows Server 2019 or later to host the connector service.
PowerShell 5.1+ running as Administrator on the connector host.
The RSAT AD PowerShell module on the host where you will create the gMSA (typically a domain controller):
Install-WindowsFeature RSAT-AD-PowerShell
Outbound HTTPS (port 443) from the connector host to api.joinploy.com.
A bearer key from the Ploy admin UI. It must start with ploy_ct_.
Download the connector
Download ploy-connector-<version>-windows-amd64.zip from the Ploy console.
Extract it to C:\Program Files\Ploy\Connector\. The folder contains:
ploy-connector.exe
config.example.yaml
INSTALL.txt
Provision a Group Managed Service Account
A gMSA is an AD-managed identity whose password rotates automatically and never needs to be stored. The connector authenticates to AD as this identity, so no password sits on the host.
Create a KDS root key
Run this once per AD forest from a domain controller if you do not already have a KDS root key:
Test-ADServiceAccount must return True. If it returns False, the most common cause is that the host is not in PrincipalsAllowedToRetrieveManagedPassword. Re-run the gMSA creation step with the correct computer name.
Grant AD permissions
In standard AD configurations, authenticated users have read access to user, group, and OU objects, so the gMSA inherits read access automatically. If your environment hardens the directory, make sure the connector can Read on user, group, organizationalUnit, and container objects under your base_dn.
Write access is only needed if you enable write features. Scope rights to the OU subtree that holds the users and groups Ploy manages, and let inheritance carry them to objects inside it. Run this on a DC as someone who can edit that OU's ACL. Set $gmsa and $ouPath for your environment. Grant only the blocks you need:
PowerShell ACL script for write access
Import-Module ActiveDirectory
$gmsa = "ploy-connector"
$ouPath = "AD:\OU=Ploy-Managed,DC=corp,DC=example,DC=com"
$sid = (Get-ADServiceAccount $gmsa).SID
$userObj = [GUID]'bf967aba-0de6-11d0-a285-00aa003049e2'
$groupObj = [GUID]'bf967a9c-0de6-11d0-a285-00aa003049e2'
$memberProp = [GUID]'bf9679c0-0de6-11d0-a285-00aa003049e2'
$allGuid = [GUID]'00000000-0000-0000-0000-000000000000'
$Allow = [System.Security.AccessControl.AccessControlType]::Allow
$Desc = [System.DirectoryServices.ActiveDirectorySecurityInheritance]::Descendents
$ScopeAll = [System.DirectoryServices.ActiveDirectorySecurityInheritance]::All
$acl = Get-Acl -Path $ouPath
# group_management: write the 'member' attribute on groups in the subtree
$acl.AddAccessRule((New-Object System.DirectoryServices.ActiveDirectoryAccessRule(
$sid,
[System.DirectoryServices.ActiveDirectoryRights]::WriteProperty,
$Allow, $memberProp, $Desc, $groupObj)))
# identity_management: create and delete user objects in the subtree
$acl.AddAccessRule((New-Object System.DirectoryServices.ActiveDirectoryAccessRule(
$sid,
[System.DirectoryServices.ActiveDirectoryRights]'CreateChild,DeleteChild',
$Allow, $userObj, $ScopeAll)))
# identity_management: full control over the user objects themselves
$acl.AddAccessRule((New-Object System.DirectoryServices.ActiveDirectoryAccessRule(
$sid,
[System.DirectoryServices.ActiveDirectoryRights]::GenericAll,
$Allow, $allGuid, $Desc, $userObj)))
Set-Acl -Path $ouPath -AclObject $acl
The member rule alone is enough for group_management. The two user-object rules are only needed where the connector provisions accounts. If managed users and groups live under different OUs, run the relevant block against each $ouPath.
Configure the connector
The service reads its config from C:\ProgramData\Ploy\Connector\config.yaml.
Replace CORP with your domain's NetBIOS name. The trailing $ is required for gMSAs. The service is registered with auto-start, so it survives reboots.
Verify the setup
Wait approximately 30 seconds, then open the Ploy admin UI and go to Integrations > Connectors. The connector should report as online with a recent heartbeat.
.\ploy-connector.exe uninstall-service
Remove-Item -Recurse "C:\ProgramData\Ploy\Connector"
Remove-ADServiceAccount ploy-connector # run on a DC
Use password-based authentication instead of gMSA
Use this only if your environment cannot use a gMSA. In config.yaml, set auth: simple and supply bind_user plus bind_password. The service can then run as LocalSystem; omit -service-account from the install command.
We strongly recommend reading the password from an environment variable rather than embedding it in the file.
Corporate proxy and internal CAs
The connector honours HTTP_PROXY, HTTPS_PROXY, and NO_PROXY environment variables set at machine scope. User-info form http://user:pass@proxy:8080 is supported.
For internal CAs, set tls.ca_bundle in config.yaml to a PEM file path. Use tls.ca_bundle_append: true to add to the system root store rather than replace it.