Skip to content

storrellas/cryptoviewer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

63 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cryptoviewer

Configure

  1. Download the code with git
git clone https://github.com/storrellas/cryptoviewer.git
  1. Create migrations
python manage.py makemigrations viewer
  1. Create entities
python manage.py migrate viewer
  1. Run server
python runserver
  1. Open browser and go to
https://localhost:8000/views/instrument/

Tutorial

  1. Views are place under viewer\views.py

  2. URL paths are place under viewer\urls.py

  3. Commands are placed under

viewer\management\commands\retrieval_instruments.py

viewer\management\commands\retrieval_trades.py

Heroku

  1. Create heroku app
heroku apps:create cryptoviewer-release
  1. Append addon
heroku addons:create heroku-postgresql
  1. Insert config variables
heroku config
  1. Run bash into dyno
heroku run bash
./manage.py makemigrations viewer
./manage.py migrate viewer
  1. Create environment
heroku config:set DERIBIT_KEY='joesmith'

[...]
DERIBIT_KEY = os.environ.get('DERIBIT_KEY', None)
[...]
  1. See Logs
sudo heroku logs -t --app=cryptoviewer-release
  1. SSH into dyno (does not include config vars)
heroku ps:exec --app=cryptoviewer-release
  1. Generate one-off dyno (includes config vars)
heroku run bash --app=cryptoviewer-release

Heroku Docker

  1. Login container
heroku container:login
  1. Create app
heroku create --app=cryptoviewer-docker
  1. Push image
sudo docker tag cryptoviewer registry.heroku.com/cryptoviewer-docker/web
sudo docker push registry.heroku.com/cryptoviewer-docker/web
  1. Release
sudo heroku container:release web --app=cryptoviewer-docker

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published