Skip to content

Commit

Permalink
Add staticfiles app and note on generating css to install instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
Edmund von der Burg authored and dracos committed Sep 7, 2012
1 parent 2fca4a4 commit 2568a4a
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
10 changes: 8 additions & 2 deletions INSTALL.rst
Expand Up @@ -95,13 +95,19 @@ development server. Do add an admin user when prompted:
source .venv/bin/activate
pip install -r requirements.txt

# Setup and run dev server
# generate the css from the sass
../bin/make_css

# Setup django install
./manage.py syncdb
./manage.py migrate mapit

# run dev server
./manage.py runserver

(Alternatively, set up a live web server however you wish - see the Deployment
Django documentation for details beyond the scope of this document.)
Django documentation for details beyond the scope of this document. Remember to
run ``./manage.py collectstatic`` too if running Django >= 1.3.)

You can then visit http://localhost:8000/ and hopefully see the default MapIt
homepage. http://localhost:8000/admin/ should show the admin interface.
Expand Down
8 changes: 8 additions & 0 deletions project/settings.py
Expand Up @@ -179,6 +179,14 @@
'django.contrib.sites',
'django.contrib.admin',
'django.contrib.gis',

'south',
'mapit',
)

# use staticfiles if Django recent enough. If not then trust that the webserver
# can handle serving the content. mySociety currently runs mapit on Django 1.2.x
# as that is the version in the Debian Squeeze package.
if django.get_version() >= '1.3':
INSTALLED_APPS += ( 'django.contrib.staticfiles', )
STATIC_URL = '/static'

0 comments on commit 2568a4a

Please sign in to comment.