Apify Discord Mirror

Updated 5 months ago

Docker DNS Mapping Deployment

At a glance

The community member has a scraping actor that needs to fetch data from 'example.com', but it points to 123.123.123.123 instead. They usually add the IP and domain in the /etc/hosts file locally, and they want to know how to achieve this via Docker or some other means in their Apify actors (Puppeteer).

The comments suggest that the community member should check the documentation for Dockerfile and the Academy for Dockerfiles and Deployment. They also recommend running Docker locally to get some insights. One community member has asked the team about the issue and will provide an update, and they also recommend an article about building and running Dockerfile locally.

The community member has tried a few scenarios to add the entries from their 'hosts' file to Docker, but it doesn't seem to work. They are still seeking help to resolve this issue.

Useful resources
Hi, so I have a scraping actor that needs to fetch data from 'example.com', but it points to 123.123.123.123 instead, usually I add ip and domain in /etc/hosts file locally, how can I can achieve this via Docker or some other means in my Apify actors(Puppeteer)?
1
S
R
m
9 comments
Hi, somebody from team will reply soon πŸ™‚
Hi, I'm not entirely sure I 100% understood the problem πŸ€” but I think it would be worthwhile to check out our documentation article for Dockerfile, as well as our Academy for Dockerfiles and Deployment
I have some entries in my /etc/hosts which I want to use in apify environment as well, how can i do that?
Any feedback? Running docker locally should give me some insights right?
can you please help here?
has anyone run docker locally and try the scraper, I am having some issue when I want to build it locally, are there any resources to this?
can you please help here
Hi I've asked the team regarding you issue and I will update you once ill get an answer
In the meantime i recommend you this article about building and running dockerfile locally
https://www.docker.com/blog/getting-started-with-docker-using-node-jspart-i/
thanks, I hope question is clear, I just want to take entries from my 'hosts' files and add it docker, so when I hit certain url or domain it goes to that IP address (from hosts), I already tried few scenarios but it seems it doesn't work
Add a reply
Sign up and join the conversation on Discord