Skip to content

Commit

Permalink
install
Browse files Browse the repository at this point in the history
  • Loading branch information
willmcgugan committed Mar 9, 2015
1 parent a7db785 commit 9a84a7a
Showing 1 changed file with 66 additions and 0 deletions.
66 changes: 66 additions & 0 deletions INSTALL.md
@@ -0,0 +1,66 @@
# Install Encrypted Notes

So you want to self-host this web application?

## Requirements


If you don't have a Python development environment set up, you will need to do the following:

````
wget https://bootstrap.pypa.io/get-pip.py
sudo python get-pip.py
sudo pip install moya
````

If you have pip installed, you will just need the last step.

## Development

To run a *development* server, navigate to `site/` and run the following:

```
moya db sync
moya auth#cmd.init
```

This will create a database and initial user. To run the server do the following:

```
moya runserver
```

Then visit http://127.0.0.1:8000

## Configure

By default this application will use a SQLITE application (db stored in a local file). In a production environment, you will probably want to use another SQL database.

To do this, create `local.ini` and put your db settings there. For example:

```
extends=production.ini
[db:main]
engine = mysql://USER:PASSWORD@localhost/mynotes
echo = no
default = yes
```

## Deploy

To deploy the app, you will need to follow the advice for deploying a Python web application with WSGI (search google for 'deploy wsgi application'). The WSGI application can be found in `site/wsgi.py`.

For example, if you are using gunicorn (http://gunicorn.org/), you could run the application with the following:

```
gunicorn wsgi:application
```


## More Information

For more information on deploying a Moya site, please see http://docs.moyaproject.com/0.5/en/deploy.html

For development documentation see http://docs.moyaproject.com

0 comments on commit 9a84a7a

Please sign in to comment.