Greenline (aka Interactive Somerville) is a tool for visualizing issues, asking questions, learning facts, and contributing ideas related to the Greenline Extension Project in Somerville, MA.
This is a fresh start, intentended to migrate the existing code base to Pinax 0.9 fresh-start.
A Pinax basic project served as starting point.
Follow documentation at virtualenv.
$ git clone git://github.com/cspanring/greenline.git
$ cd greenline
$ pip install -r requirements/project.txt
$ sudo apt-get install binutils python-setuptools postgresql-8.4-postgis postgresql-server-dev-8.4 python-psycopg2 gdal-bin python-gdal libproj-dev
...on Ubuntu 10.10 with PostGIS 1.5 for instance:
$ sudo su postgres
$ POSTGIS_SQL_PATH=/usr/share/postgresql/8.4/contrib/postgis-1.5
$ createdb -E UTF8 template_postgis
$ createlang -d template_postgis plpgsql
$ psql -d postgres -c "UPDATE pg_database SET datistemplate='true' WHERE datname='template_postgis';"
$ psql -d postgres -c "update pg_database set datistemplate = false where datname = 'template_postgis';"
$ psql -d template_postgis -f $POSTGIS_SQL_PATH/postgis.sql
$ psql -d template_postgis -f $POSTGIS_SQL_PATH/spatial_ref_sys.sql
$ psql -d template_postgis -c "GRANT ALL ON geometry_columns TO PUBLIC;"
$ psql -d template_postgis -c "GRANT ALL ON spatial_ref_sys TO PUBLIC;"
$ psql -d template_postgis -c "GRANT ALL ON geography_columns TO PUBLIC;"
$ createuser greenline
$ #Shall the new role be a superuser? (y/n) n
$ #Shall the new role be allowed to create databases? (y/n) y
$ #Shall the new role be allowed to create more new roles? (y/n) n
$ psql
$ ALTER ROLE greenline WITH password 'password';
$ \q
$ exit
$ sudo adduser greenline
$ sudo su - greenline
$ createdb greenline -T template_postgis
.. to settings.py
or create a local_settings.py
(recommended)
$ python manage.py syncdb
$ python manage.py runserver