Created
June 4, 2020 13:16
-
-
Save rohit-saharan/18f5fb74b31a3a173f7736a6be213fe9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
#env vars used: | |
#AWS_REGION: specify which region you want to access SQS from. | |
#SQS_URL: The url of the sqs queue to listen for. The AWS keys are picked up | |
# from the environment vars that we'll add later while running the worker. | |
CELERY_BROKER_TRANSPORT_OPTIONS = { | |
'region': os.getenv('AWS_REGION','us-east-1'), | |
'predefined_queues': { | |
'default': { | |
'url': os.getenv('SQS_URL') | |
} | |
} | |
} | |
broker_url="sqs://" | |
result_backend = 'rpc://' | |
enable_utc = True |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment