mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2024-11-11 04:07:48 +03:00
4999f8e4fd
* STATIC_ROOT is at the same level as BASE_DIR, not in the BASE_DIR. * STATIC_ROOT is set as an absolute path. * Set STATICFILES_DIRS so collectstatic looks in `BASE_DIR/static`, not `BASE_DIR/../static`. Fixes #11. |
||
---|---|---|
.. | ||
{{cookiecutter.repo_name}} | ||
docs | ||
requirements | ||
CONTRIBUTORS.txt | ||
LICENSE.rst | ||
Procfile | ||
README.rst | ||
requirements.txt |
{{cookiecutter.project_name}} ============================== {{cookiecutter.description}} LICENSE: BSD Deployment ------------ Run these commands to deploy the project to Heroku: .. code-block:: bash heroku create heroku addons:add heroku-postgresql:dev heroku addons:add pgbackups heroku addons:add sendgrid:starter heroku addons:add memcachier:dev heroku pg:promote HEROKU_POSTGRESQL_COLOR heroku config:add DJANGO_CONFIGURATION=Production heroku config:add DJANGO_SECRET_KEY=RANDOM_SECRET_KEY heroku config:add DJANGO_AWS_ACCESS_KEY_ID=YOUR_ID heroku config:add DJANGO_AWS_SECRET_ACCESS_KEY=YOUR_KEY heroku config:add DJANGO_AWS_STORAGE_BUCKET_NAME=BUCKET git push heroku master heroku run python {{cookiecutter.repo_name}}/manage.py syncdb --noinput --settings=config.settings heroku run python {{cookiecutter.repo_name}}/manage.py migrate --settings=config.settings heroku run python {{cookiecutter.repo_name}}/manage.py collectstatic --settings=config.settings Run this script: (TODO - automate this) .. code-block:: python from django.contrib.sites.models import Site site = Site.objects.get() site.domain = "{{cookiecutter.domain_name}}" site.name = "{{cookiecutter.project_name}}" site.save()