I want to create docker image with Tor
/aiohttp
server to use as a proxy for HTTP requests (curl
mostly). I've already prepared working Docker image (I can use external curl -x
with it), the main problem with syntax.
What I need: I need to use this image like docker run test_image curl api.ipify.org
. Main problem - I don't understand how to configure ENTRYPOINT/CMD correctly. I use supervisor
to activate services (tor/aiohttp), so the last line of my Docker image is:
ENTRYPOINT ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/supervisord.conf"]
Question: How can I configure Docker image (using ENTRYPOINT/CMD), so the image will run my curl request after activating services?
With current exec entrypoint (or shell form) it ignores curl. If I use cmd instead of entrypoint, curl works, but image ignores cmd, so services are not activated.
So need any advice about Docker logic/syntax, so I can make it work.