Skip to content
This repository has been archived by the owner on Oct 18, 2022. It is now read-only.

AIwaffle/AIwaffle_Server1

Repository files navigation

AIwaffle_server1

Version 0.1.11

Python application

Backend server for AIwaffle

Site map

  • / Index page
  • /auth/ the user login/register pages
  • /oauth/ the OAuth2 authorization
  • /api/model/ the model APIs

Documentation

Auth: auth

OAuth2: oauth2

Auth API: api_auth

Model API: model

Extra server

An internal server that runs a something unrelated to web (e.g.: computation)

Could be integrated to the web server

Deploy

  1. Clone this repo and initialize submodules
    git clone https://github.com/AIwaffle/AIwaffle_Server1.git
    git submodule update --init
  2. Install the project and dependencies
    pip3 install -e .
  3. Create instance directory
    mkdir instance
  4. Edit instance/config.py with the following contents
    SECRET_KEY = "Your Secret Key"  # Require a random string or bytes
    SQLALCHEMY_DATABASE_URI = "sqlite://"  # Change if you want different databases
    USE_EXTRA_SERVER = True  # Whether you want to run a separate extra server
    1. Other approaches

      Edit app.py

  5. Run with uWSGI
    uwsgi uwsgi.ini
    1. (Optional) Run the extra server if USE_EXTRA_SERVER=True
    python3 -m server1_extra
    1. (Optional): Configure uWSGI

      Edit uwsgi.ini

Upcoming Changes

Version 0.1.12

  • Add language constants
  • Support logging configuration

License and copyright

Licensed under the MIT license

Copyright 2019-2020

Model

Acknowledgements