Samples to try Docker proxy feature.
- Docker
- Docker Compose
docker compose build
docker compose up proxy
Open a new terminal and run the following command:
docker compose run --rm -it client python
>>> import requests as r
>>> r.get('https://example.com')
<Response [200]>
You can see the proxy is used.