Code Monkey home page Code Monkey logo

evesrp's Introduction

Build Status Documentation Status

So, this is still in-progress, and I'm putting off writing a real readme until it's closer to a real release. IN the mean time, here're some screenshots

Developing

Dependencies

In addition to the dependencies listed in setup.py/requirements.txt, EVE-SRP depends on a Javascript packages. A couple of them are Node.js command line utilities (UglifyJS2, LESS), but the majority are used as part of the user interface. To install all development dependencies at once you can use the build-deps make target:

make build-deps

This will install all of the Python and Javascript dependencies needed for developing EVE-SRP. After you've installed the dependencies, you'll need to generate the CSS and Javascript sources.

make all

If the Javascript minimization is causing a problem, you can disable it by defining the DEBUG variable for make.

DEBUG="true" make all

To run the development server, you can use the included evesrp command line utility. I recommend installing the project in editable mode to get access to it.

./setup.py develop
evesrp -c config.py runserver

Deploying

If all you want to do is run EVE-SRP, you can skip the steps above and install it from PyPI (in a virtualenv!) like this:

pip install EVE-SRP

If you're planning on using either the Brave Core or one of the OAuth-based authentication mechanisms, you'll need to install either of those options like so:

pip install EVE-SRP[BraveCore]

or

pip install EVE-SRP[OAuth,BraveCore]

You will also need the appropriate adapter for your database of choice. For example, I use PostgreSQL, and use the psycopg2 adapter:

pip install psycopg2

You then need to set up the database for your application. Continuing the example with Postgres, creating the database might look something like this:

psql -c 'CREATE DATABASE evesrp;'

Now you need to create the configuration file. This will tell EVE-SRP how to connect to the database, how users should log in, and other things like that. There's an example of an instance folder using Brave's Core and Test's OAuth provider for authentication with customized killmail processing in the 'examples' folder in the repository (browsable through GitHub).

With an instance folder set up like the example, you can then create the database tables for the app using the management command. This command is installed as part of installing the EVE-SRP package.

evesrp -i /path/to/instance/folder/ db create

The final step is setting up the WSGI part of the app. For a super simple solution, you can use the server built into Flask. The run.py file in the 'examples' folder is setup to work like this. This server is not meant for production use, and is only good for verifying that things work.

Using Heroku, you can use the same run.py file with a Procfile like this:

web: gunicorn run:app

For a standalone Nginx+uWSGI setup with Nginx listening on a Unix domain socket, your uwsgi command might looks something like this:

uwsgi -s /path/to/uwsgi.sock -H /path/to/virtualenv -w run:app

For more information on how to serve a Python app using Gunicorn, check out Flask's documentation on deployment.

Dependencies

EVE-SRP requires Python 2.7 or >=3.3 and a database (with connector) that is supported by SQLAlchemy. EVE-SRP is typically developed against PostgreSQL with the psycopg2 adapter. It is also tested regularly with the following database adapters:

evesrp's People

Contributors

abzde avatar acidity avatar adrien-f avatar paxswill avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.