When a Windows-based Plesk configuration is added in Odin Automation, to prevent conflicts between Windows Updater and Plesk installer the following scripts should be added to the Plesk configuration:
Note: These scripts also switch Plesk locale to DE.
Pre-upgrade script:
net stop wuauserv
C:\Windows\system32\reg.exe add "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v AUOptions /t REG_DWORD /d 2 /f >> \reg.log 2>&1
net start wuauserv || echo "pre-install script finished"
Post-installation script:
"C:\Program Files (x86)\Parallels\Plesk\bin\init_conf" -u -city '---'
"C:\Program Files (x86)\Parallels\Plesk\bin\server_pref" -sd -locale de-DE
FOR /F "tokens=*" %%i IN ('"C:\Program Files (x86)\Parallels\Plesk\bin\locales" -l ^| findstr -v de-DE') DO (
IF NOT %%i == "de-DE" (
"C:\Program Files (x86)\Parallels\Plesk\bin\locales" --disable %%i
)
)
"C:\Program Files (x86)\Parallels\Plesk\bin\locales" --enable en-US
"C:\Program Files (x86)\Parallels\Plesk\bin\locales" --set-default de-DE
"C:\Program Files (x86)\Parallels\Plesk\bin\admin" -u -locale de-DE
"C:\Program Files (x86)\Parallels\Plesk\bin\plesk.exe" db "update clients set locale='de-DE' where id = 1"
"C:\Program Files (x86)\Parallels\Plesk\bin\plesk.exe" db "update smb_users set locale='de-DE' where id =1"
net stop wuauserv
C:\Windows\system32\reg.exe add "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU" /v AUOptions /t REG_DWORD /d 4 /f >> \reg.log 2>&1
net start wuauserv || gpupdate /force || echo "post-install script finished"