Skip to content
Newer
Older
100644 68 lines (43 sloc) 2.02 KB
35c0dd7 Updated README with useful info.
cgroskopf authored Jun 16, 2011
1 census.ire.org
2 ==============
3
4 A nationwide census browser for 2000 and 2010 census data.
5
6 Dependencies
7 ============
8
9 You will need Python 2.7, the PostGIS stack, virtualenv and virtualenvwrapper. Mac Installation instructions at: http://blog.apps.chicagotribune.com/2010/02/17/quick-install-pythonpostgis-geo-stack-on-snow-leopard/):
10
11 Other required software:
12
13 * mongodb
14 * wget
15 * mdbtools.
16
17 On a Mac you can get these with Brew::
18
19 brew install mongodb
20 brew install wget
21 brew install mdbtools
22
23 Bootstrapping the webapp
24 ========================
25
26 To get the web application running::
27
28 cd censusweb
29 mkvirtualenv --no-site-packages censusweb
30 pip install -r requirements.txt
31 cd ../censusweb
32 ./manage.py runserver
33
34 Configuring the webapp
35 ======================
36
37 By default the webapp is going to use the data published to the IRE test site, which may not be accessible to you. To use you're own data open censusweb/config/settings.py and modify the following line::
38
39 API_URL = 'http://s3.amazonaws.com/census-test'
40
41 See the next section to learn how to deploy data to your custom S3 bucket.
42
43 Loading data
44 ============
45
46 Once you've setup the webapp you will have the requirements needed to load data. If you want to load embargoed data you will need to define environment variables for your username and password::
47
48 CENSUS_USER=cgroskopf@tribune.com
49 CENSUS_PASS=NotMyRealPassword
50
51 You will also need to have defined your Amazon Web Services credentials so that you can upload the rendered data files to S3::
52
53 export AWS_ACCESS_KEY_ID="foo"
54 export AWS_SECRET_ACCESS_KEY="bar"
55
56 You will also need to modify the load configuration to point at the same S3 bucket you configured for the webapp. Open dataprocessing/config.py and modify the following lines::
57
58 S3_BUCKETS = {
59 'staging': 'census-test',
60 'production': 'censusdata.ire.org',
61 }
62
63 To load SF1 data for Hawaii make sure you have Mongo running and then execute the following commands::
64
65 cd dataprocessing
66 ./batch_sf.sh Hawaii staging
67
Something went wrong with that request. Please try again.