-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix static files handling in production
- Loading branch information
Showing
2 changed files
with
22 additions
and
9 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,25 +5,38 @@ Development | |
----------- | ||
|
||
### Prerequisites ### | ||
* Python (2.6) | ||
* If you already have a newer version of python you will need to install 2.6 alongside your | ||
current version | ||
* Python (2.7) | ||
* pip | ||
* `easy_install pip` | ||
* virtualenv | ||
* `pip install virtualenv` | ||
|
||
### Setup ### | ||
mkdir lexTerm && cd lexTerm | ||
virtualenv -p <path_to_python2.6> --no-site-packages server | ||
virtualenv --no-site-packages server | ||
cd server | ||
source bin/activate | ||
pip install django==1.4 | ||
git clone [email protected]:LexTerm/LexTermServer.git lexTerm | ||
cd lexTerm | ||
pip install -r requirements.txt | ||
./manage.py syncdb | ||
|
||
### Run it ### | ||
cd lexTerm | ||
python manage.py runserver | ||
./manage.py runserver | ||
|
||
Production | ||
---------- | ||
|
||
### Setup ### | ||
* ssh onto the server | ||
* create a virtual environment | ||
* `git clone https://github.com/LexTerm/LexTermServer.git lexTerm` | ||
* `cd lexTerm` | ||
* `mkdir static` | ||
* In the webserver document root do `ln -s path/to/lexTerm/static static` | ||
* follow the django instructions [here] | ||
(https://docs.djangoproject.com/en/1.5/howto/deployment/fastcgi/#running-django-on-a-shared-hosting-provider-with-apache) | ||
|
||
### Deploy ### | ||
with rsync | ||
* to update, simply `git pull` in the repository | ||
|
This file contains 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