Each time this pipeline receives an item, it sends it to SQS.
- Python 3+
- Scrapy 1.1+
- boto3
pip3 install scrapy-sqspipeline
-
Add the following lines to your Scrapy project settings.
ITEM_PIPELINES = { 'sqspipeline.SQSPipeline': 100, } # Either `SQSPIPELINE_QUEUE_URL` or `SQSPIPELINE_QUEUE_NAME` is required. SQSPIPELINE_QUEUE_URL='https://sqs.ap-northeast-1.amazonaws.com/xxxxxxxxxx/scrapy-sqspipeline' # SQSPIPELINE_QUEUE_NAME=''
-
Use AWS CLI's
aws configure
command to set up credentials. Alternatively, you can use Scrapy's settingsAWS_ACCESS_KEY_ID
,AWS_SECRET_ACCESS_KEY
andAWS_REGION_NAME
.