A web crawler, Used for crawling e-commerce websites to fetch data like product price, image, and seller, etc...
A quick introduction of the minimal steps you need to get the service up & running.
python -m venv venv
Linux:
source venv/bin/activate
windows:
venv/bin/activate
pip install scrapy
pip install psycopg2
Then set your connection string in the following images (one for data seeding and the other for data insertion):
Date seeding
self.connection = psycopg2.connect(
host='localhost',
user='docker',
password='docker',
database='crawler_db'
)
Data insertion
self.engine = create_engine('postgresql://docker:docker@localhost/crawler_db')
pip install sqlalchemy
pip install flask
pip install flask_restx
I have added the requirements.txt to make installing the needed packages easier
and also I have added Dockerfile with the docker-compose to containerize the project
Simply run the following command in the directory which the docker-compose file exists
docker-compose up