I’ve been messing around with trying to get “Set-DscLocalConfigurationManager” to play nice behind a proxy server. My conclusion up until now it that this cmdlet is not proxy aware, but wanted to reach out to this community to see if anyone else ever got this to work?
Here’s my test setup:
Member1: Windows 2016 Member server
DC01: Windows 2016 DC, DNS
Edge01: Proxy server, DNS, (Optional NAT)
Member1 is the server that needs to get the DSC configuration. Member1 has proxy configuration set in IE and configured with “Netsh winhttp”. I verified that Internet connectivity works using IE, running Windows update and “Invoke-WebRequest”. When running “Set-DscLocalConfigurationManager” it fails in this setup with the error message:
“Registration of the Dsc Agent with the server https://we-agentservice-prod-1.azure-automation.net/accounts/(guid) failed. The underlying error is: Failed to register Dsc Agent with AgentId 29A9E37B-1D35-11E8-9669-00155D7CD013 with the server https://we-agentservice-prod-1.azure-automation.net/accounts/(guid)/Nodes(AgentId=‘29A9E37B-1D35-11E8-9669-00155D7CD013’)”
- I replaced the guid with (GUID)
When I use the same setup and place this machine outside of the network so that it can directly connect to Azure, or enable NAT on the proxy the registration succeeds immediately, hence my conclusion that the cmdlet is not proxy aware.
Anyone have any ideas? Is there a way to tell PowerShell in general or this specific cmdlet, “Use this proxy”?