Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 173 lines (122 sloc) 5.8 kB
f26df0a @fwenzel oops, Firefox Input, not Mozilla Input
fwenzel authored
1 Firefox Input
e6eae89 @fwenzel Production app will be called Mozilla Input. Codename remains reporter.
fwenzel authored
2 =============
f22df3b @fwenzel README file.
fwenzel authored
3
6e6fe4c @fwenzel freeing product details from the claws of the reporter app.
fwenzel authored
4 Firefox Input is a [Django][Django]-based web application to gather user
5 feedback from the [Mozilla][Mozilla] Firefox beta testing program.
f22df3b @fwenzel README file.
fwenzel authored
6
7 For project goals, specifications, etc., check out the
1db2b52 Changed the name 'Reporter' to 'Input'
Aakash Desai authored
8 [Input Wiki Page][wikimo].
f22df3b @fwenzel README file.
fwenzel authored
9
10 [Mozilla]: http://www.mozilla.org
11 [Django]: http://www.djangoproject.com/
e6eae89 @fwenzel Production app will be called Mozilla Input. Codename remains reporter.
fwenzel authored
12 [wikimo]: https://wiki.mozilla.org/Firefox/Input
f22df3b @fwenzel README file.
fwenzel authored
13
14 Getting Started
15 ---------------
16 ### Python
17 You need Python 2.6. Also, you probably want to run this application in a
18 [virtualenv][virtualenv] environment.
19
6b762b8 @fwenzel messing around with requirements to accommodate a vendor lib
fwenzel authored
20 Run
21
22 easy_install pip
23
24 followed by
25
26 pip install -r requirements/prod.txt -r requirements/compiled.txt
27
f22df3b @fwenzel README file.
fwenzel authored
28 to install the required Python libraries.
29
30 [virtualenv]: http://pypi.python.org/pypi/virtualenv
31
ddc9b5b @davedash bug 615609, higcharts pulled in
davedash authored
32 ### Highcharts
33
34 Due to licensing issues, we can't rightfully bundle highcharts.js. So you can
35 go get it using `./manage.py cron get_highcharts`.
36
1a17b5f @fwenzel (hopefully) removed all traces of haystack.
fwenzel authored
37 ### Sphinx
38
39 For searching, we use [Sphinx][sphinx]. Set up an instance of it, and adjust
ddc9b5b @davedash bug 615609, higcharts pulled in
davedash authored
40 the SPHINX\_\* settings in settings.py to match your setup.
1a17b5f @fwenzel (hopefully) removed all traces of haystack.
fwenzel authored
41
42 [sphinx]: http://www.sphinxsearch.com/
43
f22df3b @fwenzel README file.
fwenzel authored
44 ### Django
5fd6c3b @davedash DB instructions
davedash authored
45 Put your database settings in `settings_local.py`:
46
47 from settings import *
48
49 # ...
50
51 DATABASES = {
52 'default': {
53 'ENGINE': 'mysql',
54 'NAME': 'firefox_input',
55 'USER': 'root',
56 'PASSWORD': '',
57 'HOST': 'localhost',
58 'PORT': '',
59 'OPTIONS': {'init_command': 'SET storage_engine=InnoDB',
60 'charset' : 'utf8',
61 'use_unicode' : True,
62 },
fc8f7c0 @fwenzel Re-enabling website issues (and buttons) post-prod-push.
fwenzel authored
63 },
64 'website_issues': {
65 'ENGINE': 'mysql',
66 # ...
5fd6c3b @davedash DB instructions
davedash authored
67 }
68 }
69
6e6fe4c @fwenzel freeing product details from the claws of the reporter app.
fwenzel authored
70 To initialize the database, run:
71
72 ./manage.py syncdb
73
f555bcc @x1B Added documentation on schematic calls.
x1B authored
74 To update your schemas from an earlier version:
75
76 schematic migrations
77
fab8481 @fwenzel Advice on update_product_details as cron job and pulling from git.
fwenzel authored
78 To initialize the search index, run:
7ab592a @fwenzel half-done search page. Need: aggregates, narrowing options.
fwenzel authored
79
1a17b5f @fwenzel (hopefully) removed all traces of haystack.
fwenzel authored
80 ./manage.py update_index
7ab592a @fwenzel half-done search page. Need: aggregates, narrowing options.
fwenzel authored
81
f22df3b @fwenzel README file.
fwenzel authored
82 The Internet has plenty of of documentation on setting up a Django application
83 with any web server. If you need a wsgi entry point, you can find one in
84 ``wsgi/reporter.wsgi``.
85
79ad4b7 @x1B Better documentation for Sites
x1B authored
86 ### Sites data
f1f3f7f @x1B Added instruction to README to use a separate database for website_is…
x1B authored
87 The "website\_issues" database has to be a separate SQL-database from
88 "default", as it uses its own schematic migration version.
79ad4b7 @x1B Better documentation for Sites
x1B authored
89 It is used to load aggregate website issues (generated by clustering) from a
90 cron task. To initialize it, run:
91
92 ./manage.py syncdb --database=website_issues
93
94 To generate site data yourself without getting it pushed from metrics, run
95
96 ./manage.py generate_sites
97
f555bcc @x1B Added documentation on schematic calls.
x1B authored
98 And for schema updates:
99
100 schematic migrations/sites
101
7ab592a @fwenzel half-done search page. Need: aggregates, narrowing options.
fwenzel authored
102 ### Cron jobs
fab8481 @fwenzel Advice on update_product_details as cron job and pulling from git.
fwenzel authored
103 There are two jobs you may want to run periodically:
7ab592a @fwenzel half-done search page. Need: aggregates, narrowing options.
fwenzel authored
104
105 ./manage.py update_product_details # Mozilla Product Details update
fab8481 @fwenzel Advice on update_product_details as cron job and pulling from git.
fwenzel authored
106 ./manage.py update_index -r # update and rotate search index
7ab592a @fwenzel half-done search page. Need: aggregates, narrowing options.
fwenzel authored
107
108 The frequency is up to you, but you probably want to run the search index
109 updates relatively frequently, while the product details can wait a little
110 longer.
111
fab8481 @fwenzel Advice on update_product_details as cron job and pulling from git.
fwenzel authored
112 Note that updating the product details files like this will lead to "local
113 changes" in your checkout. If you plan on pulling code updates from git
114 periodically, you should leave ``lib/product_details_json`` untouched, but
115 create a new directory somewhere else and change the setting
116 ``PROD_DETAILS_DIR`` accordingly.
117
24b19dd @fwenzel mobile site framework, serving desktop site on site ID 1, and mobile …
fwenzel authored
118 ### Mobile vs. Desktop site
119 We are using the [Django Sites Framework][sites] to distinguish between the
120 mobile site and the desktop site. The default is site ID 1 == desktop. If
121 you create another site using the admin interface, requests for that site's
122 domain will show the mobile site (set ``settings.MOBILE_SITE_ID`` accordingly,
123 though the default of 2 is probably correct).
124
125 For development, you can create an alias of localhost (``m.localhost``, for
126 example) in ``/etc/hosts``, and use that as the domain for the second site.
127 Make sure to include the port (``m.localhost:8000``).
128
129 [sites]: http://docs.djangoproject.com/en/dev/ref/contrib/sites/
130
131
f22df3b @fwenzel README file.
fwenzel authored
132 License
133 -------
134 This software is licensed under the [Mozilla Tri-License][MPL]:
135
136 ***** BEGIN LICENSE BLOCK *****
137 Version: MPL 1.1/GPL 2.0/LGPL 2.1
138
139 The contents of this file are subject to the Mozilla Public License Version
140 1.1 (the "License"); you may not use this file except in compliance with
141 the License. You may obtain a copy of the License at
142 http://www.mozilla.org/MPL/
143
144 Software distributed under the License is distributed on an "AS IS" basis,
145 WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
146 for the specific language governing rights and limitations under the
147 License.
148
f26df0a @fwenzel oops, Firefox Input, not Mozilla Input
fwenzel authored
149 The Original Code is Firefox Input.
f22df3b @fwenzel README file.
fwenzel authored
150
151 The Initial Developer of the Original Code is Mozilla.
152 Portions created by the Initial Developer are Copyright (C) 2010
153 the Initial Developer. All Rights Reserved.
154
155 Contributor(s):
156 Frederic Wenzel <fwenzel@mozilla.com>
157
158 Alternatively, the contents of this file may be used under the terms of
159 either the GNU General Public License Version 2 or later (the "GPL"), or
160 the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
161 in which case the provisions of the GPL or the LGPL are applicable instead
162 of those above. If you wish to allow use of your version of this file only
163 under the terms of either the GPL or the LGPL, and not to allow others to
164 use your version of this file under the terms of the MPL, indicate your
165 decision by deleting the provisions above and replace them with the notice
166 and other provisions required by the GPL or the LGPL. If you do not delete
167 the provisions above, a recipient may use your version of this file under
168 the terms of any one of the MPL, the GPL or the LGPL.
169
170 ***** END LICENSE BLOCK *****
171
172 [MPL]: http://www.mozilla.org/MPL/
Something went wrong with that request. Please try again.