| 1 | If you're not running a Linux machine, the easiest way for (me to show you how) |
|---|
| 2 | you can install the database is probably to run it on scripts.mit.edu, so here |
|---|
| 3 | are instructions for that. |
|---|
| 4 | |
|---|
| 5 | You should ssh into an Athena machine (for example, athena.dialup.mit.edu). |
|---|
| 6 | |
|---|
| 7 | Once there, run "add scripts; scripts-django". That will ask you various |
|---|
| 8 | questions, that I think are mostly straightforward to answer. I'm going |
|---|
| 9 | to assume that you'll pick ~"1. Install into my locker.", give a path of |
|---|
| 10 | "asa-db", and a project name of "asadb". Once you finish that, you'll |
|---|
| 11 | have a generic Django install, which we need to turn into an ASA DB |
|---|
| 12 | install (going roughly off the instructions at |
|---|
| 13 | http://scripts.mit.edu/faq/127/how-can-i-import-an-outside-django-project). |
|---|
| 14 | Adjust the directions below appropriately if you picked other options. |
|---|
| 15 | |
|---|
| 16 | In the directions below, where `adehnert` appears you should instead put your |
|---|
| 17 | username. |
|---|
| 18 | |
|---|
| 19 | # 2. Move the autoinstalled version aside |
|---|
| 20 | cd /mit/$USER/Scripts/django/ |
|---|
| 21 | mv asa-db{,.auto} |
|---|
| 22 | |
|---|
| 23 | # 3. Download the ASA DB code |
|---|
| 24 | git clone https://asa-db.scripts.mit.edu/git/asa-db/asa-db.git asadb |
|---|
| 25 | |
|---|
| 26 | # 4. Fix index.fcgi |
|---|
| 27 | nano /mit/$USER/web_scripts/asadb/index.fcgi |
|---|
| 28 | # Add "sys.path.insert(0, "/mit/adehnert/Scripts/django/asa-db/asadb")" |
|---|
| 29 | # just below the other sys.path.insert line |
|---|
| 30 | |
|---|
| 31 | # 5. Add the media symlink |
|---|
| 32 | ln -s ../../Scripts/django/asa-db/asadb/media/ ../../web_scripts/asa-db/ |
|---|
| 33 | |
|---|
| 34 | # 6. Configure your settings |
|---|
| 35 | cd asa-db/asadb/ |
|---|
| 36 | cp settings/local_settings.scripts.py local_settings.py |
|---|
| 37 | cp settings/local_settings_after.scripts.py local_settings_after.py |
|---|
| 38 | nano local_settings.py |
|---|
| 39 | # update the database name ("adehnert+asadb"), replace testing@mit.edu |
|---|
| 40 | # with "adehnert@mit.edu", and use the supplied Python snippet to set |
|---|
| 41 | # SECRET_KEY. |
|---|
| 42 | # https://asa.scripts.mit.edu:444 should be adehnert, not asa. |
|---|
| 43 | # I *think* everything else should be fine. |
|---|
| 44 | |
|---|
| 45 | # 7. Install dependencies |
|---|
| 46 | # (see http://scripts.mit.edu/faq/126) |
|---|
| 47 | add consult |
|---|
| 48 | mkdir -p /mit/$USER/.local/lib/python2.7/site-packages/ |
|---|
| 49 | fsr sa /mit/$USER/.local/lib/python2.7/site-packages/ daemon.scripts write |
|---|
| 50 | mkdir -p /mit/$USER/Scripts/ |
|---|
| 51 | fs sa /mit/$USER/Scripts/ daemon.scripts write |
|---|
| 52 | |
|---|
| 53 | ssh $USER@scripts.mit.edu |
|---|
| 54 | cd /mit/$USER/Scripts/ |
|---|
| 55 | easy_install --user -Z django-form-utils django-reversion |
|---|
| 56 | pip-python install --user -e git+https://github.com/alex/django-filter.git#egg=django-filter) |
|---|
| 57 | |
|---|
| 58 | # 8. Set up the database backend |
|---|
| 59 | cd /mit/$USER/Scripts/django/asa-db/asadb/ |
|---|
| 60 | ./manage.py syncdb |
|---|
| 61 | ./manage.py migrate |
|---|
| 62 | |
|---|
| 63 | At this point, it should be working. If it doesn't, debug or get a more |
|---|
| 64 | experienced developer to help you do so. |
|---|
| 65 | |
|---|
| 66 | In general, the obvious next thing for new contributors to do is to look at |
|---|
| 67 | https://asa.scripts.mit.edu/trac/query and |
|---|
| 68 | https://asa.scripts.mit.edu/trac/wiki/PossibleNextTickets (more the latter), |
|---|
| 69 | and see if there's a couple things listed there that look like fun to fix |
|---|
| 70 | (probably with "Size: small" or "Size: tiny"). Take a shot at fixing them, |
|---|
| 71 | or ask a more experienced developer to help you. |
|---|