Steps to create a postgres database and deply a Python app to Heroku
pipenv install gunicorn
or
pip install gunicorn
| # NOTE: | |
| # You can find an updated, more robust and feature-rich implementation | |
| # in Zeno Build | |
| # - Zeno Build: https://github.com/zeno-ml/zeno-build/ | |
| # - Implementation: https://github.com/zeno-ml/zeno-build/blob/main/zeno_build/models/providers/openai_utils.py | |
| import openai | |
| import asyncio | |
| from typing import Any |
| /* Useful celery config. | |
| app = Celery('tasks', | |
| broker='redis://localhost:6379', | |
| backend='redis://localhost:6379') | |
| app.conf.update( | |
| CELERY_TASK_RESULT_EXPIRES=3600, | |
| CELERY_QUEUES=( | |
| Queue('default', routing_key='tasks.#'), |
| /* fonts */ | |
| /* ------------------------------------------------------------------------- */ | |
| /* reset */ | |
| /* ------------------------------------------------------------------------- */ | |
| @import url('css/reset.css'); | |
| @import url('css/normalize.min.css'); |