mirror of
https://github.com/ProxymanApp/Proxyman.git
synced 2026-04-25 16:15:55 +03:00
[GH-ISSUE #419] Docker support #418
Labels
No labels
Discussion
Feature request
In Progress...
Plugins
Waiting response
Windows
Windows
bug
duplicate
enhancement
feature
good first issue
iOS
macOS 10.11
question
wontfix
✅ Done
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Proxyman#418
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @aprofromindia on GitHub (Feb 27, 2020).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/419
Originally assigned to: @NghiaTranUIT on GitHub.
Proxyman 1.17.1
macOS 10.15.3
Docker for Mac Desktop 2.2.0.3
Is it possible to intercept network calls being initiated by an application running (e.g. a node app) inside a docker container please?
If yes, is there a guide or info for it please?
Tried to enable HTTPS response for
com.docker.vpnkitwith no luck.@NghiaTranUIT commented on GitHub (Feb 27, 2020):
Hey @aprofromindia , Thank for suggesting the idea. We will look forward to write a blog "Docker and Proxyman" in next weeks.
For now, I suggest to Google "Docker Charles Proxy" or "Docker and Fiddler" since they are the same approach. Ex:
@aprofromindia commented on GitHub (Feb 27, 2020):
i have tried 2 things, setup proxies in ~/.docker/config.json (https://docs.docker.com/network/proxy/) and Docker for Mac Desktop Proxy Resources Preference panel, using the following IP : -
with no success :)
@NghiaTranUIT commented on GitHub (Feb 28, 2020):
It's tricky indeed. I follow some tutorials on Google to setup Charles, Fiddler with Docker, but no luck at all 😢
@TofPlay commented on GitHub (Mar 26, 2020):
Any update about Docker and Proxyman?
@NghiaTranUIT commented on GitHub (Mar 26, 2020):
Unfortunately, I attempted a lot of tutorials and StackOverflow, but there is no luck. Basically, Docker doesn't work well with Proxyman and other proxy apps since it's difficult to navigate all docket traffic to different 9090 port 😢
If you could find any tutorials, which work with Charles Proxy, mitmproxy or Fidder, it should work with Proxyman. Or find the way to override the Proxy Config from Docker
@TofPlay commented on GitHub (Apr 3, 2020):
@NghiaTranUIT Have you tried changing the configuration of the Docker?
see Configure Docker to use a proxy server
@NghiaTranUIT commented on GitHub (Apr 3, 2020):
yup, I did, but for some reason, the traffic doesn't go to the proxy as a config.
I guess it's from my end. Would be great if you try it? Please let me know the result if it works for you 👍
@aprofromindia commented on GitHub (Apr 3, 2020):
Actually docker for Mac automatically gets the proxy IP from mac system settings. So we don't need to alter anything in docker settings or configs.
Moreover I see the HTTPS calls being detected but not properly displayed, maybe its got to do with private certificates?
@TofPlay commented on GitHub (Apr 3, 2020):
On my Mac proxyman does not see a com.docker.vpnkit process

@ritchxu commented on GitHub (Feb 19, 2021):
Today I spent sometime trying to tackle a similar problem and found something that hopefully can help.
My setup is running a minikube cluster on macOS. In some way you could compare that to docker container running in Docker Desktop, since both sets up a VM as the docker host and runs containers on the VM. There are a few key points to be connected for this to work. I'm using the minikube cluster as an example:
./~proxyman/proxyman-ca.pemneeds to be added to the container and trusted as CAWith settings above I was able to do a simple test and see the traffic captured by Proxyman. You may need to enable the domain in Proxy to see the response.
@NghiaTranUIT commented on GitHub (Feb 19, 2021):
Thanks for your contribution @ritchxu It's useful for anyone who is using Docker + Proxyman ❤️
@nathanbrock commented on GitHub (Mar 4, 2022):
Thanks, @ritchxu, your comment was a great starting point for getting Docker working with Proxyman.
Just wanted to add a couple extra pointers that I've found useful when using Docker with Proxyman for those, like me, who found this issue whilst Googling.
HTTP_PROXYandHTTPS_PROXYenvironment variables to point to Proxyman on the host results in the URL being correctly resolved, with or without SSL proxying enabled. Using Dockers transparent proxy option (Docker > Preferences > Resources > Proxies) works ok, but due to the way vpnkit seems to be routing requests the resulting entries in Proxyman are lacking DNS information. Like in the screenshot in @aprofromindia's comment.update-ca-certificatedoesn't always seem to play ball. I was debugging a Serverless framework offline setup and the proxyman certificate wasn't being picked up by the lambci/lambda:go1.x container being spun up. In the end I had to add the proxyman CA certificate directly to/etc/pki/tls/certs/ca-bundle.crt. Probably not the best approach but worked for debugging purposes. In this very specific example I also had to rebuild the lambci container after starting the serverless process, but that's something unrelated. I've documented the above in more detail at https://www.nthbrock.com/posts/proxyman-with-docker/.Big thanks for building Proxyman, it's incredibly useful and a big help day-to-day!
@NghiaTranUIT commented on GitHub (Mar 4, 2022):
Thanks @nathanbrock for your solution. I appreciate it 👍
I will add your note to our Documentation 🙌
@sandrodz commented on GitHub (Oct 8, 2022):
I couldn't make this work, even after following some tips in comments here.
My image is
php:7.4-fpm-alpineAdded following to it:
but from within docker container when proxyman is running I get:
curl -iv https://google.com
I can confirm that
/etc/ssl/certs/ca-certificates.crtcontainsproxyman-ca.pemas a last item.any ideas where I could look?
@NghiaTranUIT commented on GitHub (Oct 10, 2022):
@sandrodz You might temporarily fix it by using the
-kflag on the cURL.Look like the cURL doesn't proxy to Proxyman, it uses Proxyman-CA as a certificate. It doesn't have google.com in the
subjectAltName=> Rejected by cURL.@sandrodz commented on GitHub (Oct 10, 2022):
Docker is proxied to Proxyman, and curl I am running inside docker container. Sure
-kworks, but I a have php application running in this container and I've to set it everywhere for php curl too. Kind of makes everything complicated.@sandrodz commented on GitHub (Oct 10, 2022):
You said
temporarywill there be a permanent solution? I would like to buy license for the proxyman, but without docker compatibility this its kind of useless to me.@NghiaTranUIT commented on GitHub (Oct 10, 2022):
Unfortunately, it's not a bug from Proxyman. It's how you set up a MITM proxy with Docker + PHP server.
@sandrodz commented on GitHub (Oct 10, 2022):
So what would be the correct way to set it up?
@haexyh commented on GitHub (Apr 3, 2024):
I'm just wondering if there are some intentions to work on it?
@NghiaTranUIT commented on GitHub (Apr 3, 2024):
@haexyh it's really a a bug from Proxyman. It's how setup Docker + your local server to work with Proxyman.
Can you try this Automatic Setup tool? It opens the pre-configured Terminal -> Open the docker and start your docker image here.
This terminal also automatically override the proxy and trust Proxyman self-signed certificate on your local server (Ruby, Python, or NodeJS), so it might work 👍