PK [ICJ>A1 1 ( cookiecutter-django-cms-0.2.3/usage.html
First, get and install cookiecutter in your virtualenv:
$ pip install cookiecutter
Now run it against this repo:
$ cookiecutter https://github.com/palazzem/cookiecutter-django-cms.git --checkout 0.2.3
You’ll be prompted for some project configurations:
full_name (default is "Michael Scott")?
email (default is "bestboss.scott@example.com")?
github_username (default is "mscott")?
year (default is "2013")?
version (default is "0.1.0")?
project_name (default is "Django CMS")?
repo_name (default is "django-cms-web")?
django_cms_app (default is "django_cms")?
project_short_description (default is "Django CMS boilerplate to start your website in 5 minutes.")?
languages (default is "en")?
site_name (default is "example.com")?
django_filer (default is "n")?
heroku (default is "y")?
Now you are ready to use Django CMS!
Like any other Django project you should do these extra steps (if you are a Djangonaut, skip this).
Install all development requirements in your virtualenv:
$ pip install -r requirements/development.txt
Sync your database with migrations:
$ python manage.py syncdb --all --settings=django_cms.settings.dev
$ python manage.py migrate --fake --settings=django_cms.settings.dev
Run all Django CMS check and start django runserver:
$ python manage.py cms check --settings=django_cms.settings.dev
$ python manage.py runserver --settings=django_cms.settings.dev
Open http://localhost:8000 and create your first page with Django CMS admin!
Note
You can avoid to use --settings parameter if you export DJANGO_SETTINGS_MODULE=django_cms.settings.dev in your environment
Note
django_cms package could have a different name according to your initial choose
For more Django CMS configurations, check official documentation (still in beta).
None yet. Why not be the first?
Contributions are welcome, and they are greatly appreciated! Every little bit helps, and credit will always be given.
If you want to add your bootstrap template, simply submit a pull request:
Note
It’s better to provide generic templates that could be customized by end users. Don’t put your already customized template or third party template with Copyright license.
Submit a pull request and edit all required settings to provide new deployment platforms. Be sure to:
New features:
Bug fixes:
Other changes:
Warning
All these steps follow the Django CMS documentation (still in beta). However this is ONLY a cookiecutter template and there is NO INTENTION to replace the official documentation.
Features?
Before continue, be sure to create your git repository:
$ git init
$ git add .
$ git commit -m"Initial commit"
Note
Generated project already have a valid .gitignore for Django
If you choose to enable Heroku deployment during project bootstrap, you already have anything you need. Simply obtain Heroku Toolbelt and start creating your first application:
$ heroku apps:create <app_name>
$ git push heroku master
You have deployed your website in Heroku platform but you need to achieve some extra steps.
Note
Check ALLOWED_HOSTS setting or you will get a 400 (bad request) error when in production
Set these enviroment variables so production configuration will work like expected:
$ heroku config:set DJANGO_SECRET_KEY=<random secret key>
$ heroku config:set DJANGO_SETTINGS_MODULE=django_cms.settings.production
Note
django_cms package could have a different name according to your initial choose
Configure your AWS bucket and add these environment variables to Heroku:
$ heroku config:set AWS_ACCESS_KEY_ID=<random key_id>
$ heroku config:set AWS_SECRET_ACCESS_KEY=<random access_key>
$ heroku config:set AWS_STORAGE_BUCKET_NAME=<your bucket name>
Run these commands using Heroku run:
$ heroku run python django_cms/manage.py syncdb --all
$ heroku run python django_cms/manage.py migrate --fake
$ heroku run python django_cms/manage.py collectstatic
Note
django_cms package could have a different name according to your initial choose
That’s all! Your Django CMS website is deployed on Heroku platform!
Cookiecutter template to be up and running with Django CMS as fast as possible! A simple bootstrap template is available and you can use it as a base for your website.