Place enrolled clients in policy OU

This commit is contained in:
2026-09-03 11:43:01 -06:00
parent 1014e24880
commit d50a4d9895
2 changed files with 13 additions and 1 deletions
+9 -1
View File
@@ -51,6 +51,7 @@ powershell.exe -NoProfile -ExecutionPolicy Bypass `
-ClientCertificateThumbprint CLIENT_CERT_THUMBPRINT ` -ClientCertificateThumbprint CLIENT_CERT_THUMBPRINT `
-ServerCertificateThumbprint SERVER_CERT_THUMBPRINT ` -ServerCertificateThumbprint SERVER_CERT_THUMBPRINT `
-DotNetRuntimeInstallerPath C:\SGUDeploy\dotnet-runtime-10-win-x64.exe ` -DotNetRuntimeInstallerPath C:\SGUDeploy\dotnet-runtime-10-win-x64.exe `
-ComputerOuDn 'OU=Laboratorio,DC=lci,DC=lasalle,DC=mx' `
-NewComputerName LAB-W11-001 -NewComputerName LAB-W11-001
``` ```
@@ -62,7 +63,7 @@ Orden de la transacción:
3. instala el guard de autorreparación; 3. instala el guard de autorreparación;
4. exige health mTLS del broker y ejecuta las comprobaciones locales; 4. exige health mTLS del broker y ejecuta las comprobaciones locales;
5. configura DNS del dominio; 5. configura DNS del dominio;
6. sólo entonces ejecuta `Add-Computer` y reinicia; 6. sólo entonces ejecuta `Add-Computer` en `OU=Laboratorio` y reinicia;
7. al arrancar, el guard habilita RDP, NLA y WinRM y comprueba el estado final. 7. al arrancar, el guard habilita RDP, NLA y WinRM y comprueba el estado final.
La directiva de Windows **Assign a default credential provider** selecciona SGU La directiva de Windows **Assign a default credential provider** selecciona SGU
@@ -73,6 +74,13 @@ permanece el mosaico genérico **Other user**. No se instala ningún filtro: el
proveedor de contraseña de Microsoft permanece disponible para cuentas creadas proveedor de contraseña de Microsoft permanece disponible para cuentas creadas
manualmente y recuperación. manualmente y recuperación.
La GPO existente **Deploy VSCodium** debe estar vinculada una vez a
`OU=Laboratorio` (configuración de equipo) y a `OU=Usuarios-SGU` (configuración
de usuario: fondo institucional). El parámetro `ComputerOuDn` coloca los
equipos nuevos directamente en `Laboratorio`; VSCodium se instala en el
siguiente arranque síncrono y el fondo se aplica al siguiente inicio de sesión
del usuario SGU.
En el controlador de dominio, aplicar una vez la directiva de usuario al árbol En el controlador de dominio, aplicar una vez la directiva de usuario al árbol
completo `Usuarios-SGU`: completo `Usuarios-SGU`:
+4
View File
@@ -18,6 +18,7 @@ param(
[PSCredential]$DomainCredential, [PSCredential]$DomainCredential,
[string]$DomainName = 'lci.lasalle.mx', [string]$DomainName = 'lci.lasalle.mx',
[string]$DomainNetbios = 'LCI', [string]$DomainNetbios = 'LCI',
[string]$ComputerOuDn = 'OU=Laboratorio,DC=lci,DC=lasalle,DC=mx',
[string]$NewComputerName, [string]$NewComputerName,
[string]$NetworkInterfaceAlias = 'Ethernet', [string]$NetworkInterfaceAlias = 'Ethernet',
[string[]]$DomainDnsServerAddresses = @('192.168.50.10'), [string[]]$DomainDnsServerAddresses = @('192.168.50.10'),
@@ -109,6 +110,9 @@ if ($PSCmdlet.ShouldProcess($env:COMPUTERNAME, 'Install and verify SGU before jo
Credential = $DomainCredential Credential = $DomainCredential
Force = $true Force = $true
} }
if ($ComputerOuDn) {
$joinParams.OUPath = $ComputerOuDn
}
if ($NewComputerName) { if ($NewComputerName) {
$joinParams.NewName = $NewComputerName $joinParams.NewName = $NewComputerName
} }