Last active
August 29, 2015 13:57
-
-
Save escowles/9739653 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SFM Mac notes: | |
| Install postgres and python using homebrew: | |
| $ brew install postgres python | |
| Install virtualenv: | |
| $ pip install virtualenv | |
| The virtualenv install guide I read (http://hackercodex.com/guide/python-development-environment-on-mac-osx/) recommended setting these environment variables: | |
| # pip should only run if there is a virtualenv currently activated | |
| export PIP_REQUIRE_VIRTUALENV=true | |
| # cache pip-installed packages to avoid re-downloading | |
| export PIP_DOWNLOAD_CACHE=$HOME/.pip/cache | |
| Setup postgres database: | |
| $ initdb /usr/local/var/postgres -E utf8 | |
| $ pg_ctl -D /usr/local/var/postgres -l /usr/local/log/postgres.log start | |
| $ createdb sfm | |
| $ createuser sfm -P | |
| Enter password for new role: ******** | |
| Enter it again: ******** | |
| Test connecting to postgres: | |
| $ export PGPASSWORD=xyz | |
| $ psql -U sfm -d sfm | |
| Then start sfm readme: | |
| $ git clone git://github.com/gwu-libraries/social-feed-manager.git | |
| $ cd social-feed-manager | |
| $ virtualenv --no-site-packages ENV | |
| $ source ENV/bin/activate | |
| $ pip install -r requirements.txt | |
| $ cd sfm/sfm | |
| $ cp local_settings.py.template local_settings.py | |
| Create a twitter app | |
| Edit sfm/sfm/local_settings.py and add twitter keys | |
| Edit sfm/sfm/wsgi.py | |
| Setup db: | |
| $ cd social-feed-manager/sfm | |
| $ ./manage.py syncdb | |
| $ ./manage.py migrate | |
| Edit edit social-feed-manager/sfm/sfm/apache.conf | |
| /PATH/TO -> /Users/escowles/src/social-feed-manager | |
| YOUR/VENV -> ENV | |
| YOUR-HOST-NAME -> melendor.local | |
| Install apache config | |
| $ sudo cp sfm/apache.conf /etc/apache2/other/ | |
| $ sudo apachectl restart | |
| Start server and open sfm in a browser: | |
| $ ./manage.py runserver | |
| $ open http://localhost:8000/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment