/restful-python-planetary-api

My source code after taking the Lynda.com course "Building RESTful APIs with Flask"

Primary LanguagePython

Python Planetary API

My source code after taking the Lynda.com course: Building RESTful APIs with Flask

Setup and run

  1. Clone this repo and cd into it
  2. touch planets.sqlite
  3. python3 -m pip install --user virtualenv
  4. python3 -m venv env

Run the app

  1. source env/bin/activate
  2. export FLASK_DEBUG=1 && export FLASK_APP=app.py
  3. pip install -r requirements.txt
  4. flask run

Control + C will stop the web server.

Seeding the database

  1. flask db_create
  2. flask db_seed will seed the database

When you are done with the virtualenv, use: deactivate.

Updating the requirements.txt file

pip freeze > requirements.txt