annotate backend.py @ 161:f307d4cdc3fb

Setup Wikked Pypi package: - Moved all assets into `wikked/assets` for proper packaging. - Added `setuptools` stuff.
author Ludovic Chabant <ludovic@chabant.com>
date Fri, 10 Jan 2014 23:12:10 -0800
parents 87606db8c641
children a4a64d6b66cb
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
138
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
1 import logging
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
2 from celery import Celery
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
3
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
4
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
5 logging.basicConfig(level=logging.DEBUG)
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
6
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
7
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
8 app = Celery(
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
9 'wikked',
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
10 broker='amqp://',
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
11 backend='amqp://',
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
12 include=['wikked.tasks'])
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
13
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
14 if __name__ == '__main__':
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
15 app.start()
df04e6a875ba Added Celery-powered background updates to wiki pages.
Ludovic Chabant <ludovic@chabant.com>
parents:
diff changeset
16