it's easy
In the WSUS GPO assigned to this server, DISABLE the policy "Specify intranet Microsoft update service location
To exclude your server from WSUS GPO:
Choose your GPO policy -> go to delegation tab -> Advanced -> Grant "Deny" permission on "Apply Group Policy" to your server
If you use registry, delete the entire registry key HKLM\Software\Policies\Microsoft\Windows\WindowsUpdate.
https://social.technet.microsoft.com/Forums/en-US/eff10fab-7ca3-471e-a164-bf7b73a28128/how-to-remove-wsus-client-settings?forum=winserverwsus