-
Notifications
You must be signed in to change notification settings - Fork 8.1k
WIP: Add UnixSocket to WebCmdlets #18995
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
This pull request has been automatically marked as Review Needed because it has been there has not been any activity for 7 days. |
|
After the latest change the tests work on Windows and MacOS but still fail on Linux. The error originates from the -Certificate parameter. @rjmholt you made the SelfSignedCertificate module, maybe you can help me solve this problem. |
Unix sockets are supported on Windows https://devblogs.microsoft.com/commandline/af_unix-comes-to-windows/
|
|
This PR has Quantification details
Why proper sizing of changes matters
Optimal pull request sizes drive a better predictable PR flow as they strike a
What can I do to optimize my changes
How to interpret the change counts in git diff output
Was this comment helpful? 👍 :ok_hand: :thumbsdown: (Email) |
|
@olljanat I will add some tests after we figure out the failures on linux tests. |
|
@iSazonov are you aware of some real world application which uses unix sockets and is available for Windows? |
I don't know. I guess main motivation was to open easy way to port Unix applications to Windows and develop new cross-platform applications. |
|
@iSazonov sure I get that but @CarloToso asked above testing in Windows so we need find (or build) some app to be able to do so. |
|
@iSazonov @olljanat Maybe this could be a good starting point https://stackoverflow.com/questions/64713218/is-there-an-af-unix-support-on-windows-for-windows-wsl-interop-on-net-core
|
|
We don't need to have a real application. We can create simple helper app. |
|
This pull request has been automatically marked as Review Needed because it has been there has not been any activity for 7 days. |
|
Replaced by #19343 |

PR Summary
Untested and in an early stage, it probably won't work yet.
This PR aims to add
-UnixSocketsupport toInvoke-WebRequestandInvoke-RestMehtodSystem.Net.HttpClientHandlertoSystem.Net.Http.SocketsHttpHandlerto exposeConnectCallbackhandler.ClientCertificateOptions = ClientCertificateOption.Manual;, it might no longer be necessary)-UnixSocketparameterSyntax:
curl --unix-socket /var/run/docker.sock http://v1.40/images/jsonInvoke-WebRequest -Uri "http://v1.40/images/json/" -UnixSocket "/var/run/docker.sock"The tests highlight some problems with the
Certificates-> when using both-Certificateand-SkipCertificateCheckon LinuxI think we'll have to update the 2 failing testsPR Context
#12060 and #8314
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:or[ WIP ]to the beginning of the title (theWIPbot will keep its status check atPendingwhile the prefix is present) and remove the prefix when the PR is ready.(which runs in a different PS Host).