JF
jferragut/Class-Project-Backend
Crypto Tracker Backend API - Provides all hooks for database manipulation
Installation
- Change your python version to 3
$ sudo mv /usr/bin/python /usr/bin/python2
$ sudo ln -s /usr/bin/python3 /usr/bin/python- Download django and rest_framework
$ sudo pip install django
$ sudo pip install djangorestframework- Start a django website
$ django-admin startproject <project-name>
& cd <project-name>A django project is divided in one or more apps, that way you can re-use any app on other proyects.
- Create your first app
$ python manage.py startapp <app1_name>- Run the migrations
$ python manage.py migrate- Add your website URL to the ALLOWED_HOSTS on settings.py
ALLOWED_HOSTS = [
'django-example-alesanchezr.c9users.io',
]- Run django on c9 ports by doing
$ python manage.py runserver $IP:$PORTAditional Tutorials
/blob/master/quick_tutorials/ADMIN.md
- Create admin users to create users, etc.
- Typical workflow for any API method to create users, etc.
- Working with the database objects to create users, etc.
- Working with Migrations to create users, etc.
- Using Mongo to create users, etc.