Alestainer / dockerized-scraper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

dockerized-scraper

Description

This software scrapes Honolulu county permitting data and stores it in the MongoDB instance.

How to use

  1. `git clone https://github.com/alestainer/dockerized-scraper'

  2. Run npm install in both hnl_property_scraper and screst folders

  3. Install Docker from https://www.docker.com/get-docker

  4. Start Docker and run docker-machine ip

  5. Create environment variables MONGO_URL, MONGO_USER, MONGO_PASS, and DOCKER_SERVER using your own credentials, address of your MongoDB instance, and docker machine ip you got from the previous step.

  6. In hnl-property-scraper folder run docker build -t scrimage .

  7. In screst folder run docker build -t restimage .

  8. In docker console docker swarm init --advertise-addr $DOCKER_SERVER

  9. docker stack deploy -c docker-compose.yml scaledScraper

  10. To check the workers docker service logs scaledScraper_scraper

About


Languages

Language:JavaScript 83.7%Language:HTML 15.6%Language:Dockerfile 0.7%