Go to file
Nicholas Clarke f3e7596fe4 Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
api Add Drawing Templates functionality 2020-07-16 19:48:20 +03:00
charting_library_charts Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
model Warnings formatter && Prometheus metrics 2022-06-07 16:11:38 +03:00
ssl_backend Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
.gitignore Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
ProcFile Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
README.md docs: change line number of DATABASES 2021-12-13 12:47:18 +00:00
manage.py Initial commit 2014-10-07 17:07:00 +04:00
notes.md Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
requirements.txt Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00
runtime.txt Add custom postgres backend for ssl. Add ProcFile. 2023-04-08 21:34:22 -07:00

README.md

Charting Library Save/Load Backend

This is the tiny backend implementing Charting Library charts storage.

Requirements

Python 3x, pip, Django, Postgresql

How to start

  1. Install Python 3.x and Pip. Use virtual environment if your host has older python version and it cant be upgraded.
  2. Install PostgreSQL or some other Django-friendly database engine. Also you might want to install PgAdmin or any other administrative tool for your database.
  3. Go to your charts storage folder and run pip install -r requirements.txt. Unix users : you have to have python-dev package to install psycopg2.
  4. Create an empty database in Postgres (using either command line or pgadmin). Go to charting_library_charts folder and set up your database connection in settings.py (see DATABASES @ line #16).
  5. Run python manage.py migrate. This will create database schema without any data.
  6. Generate a secret key by running python -c 'from django.core.management.utils import get_random_secret_key; print(get_random_secret_key())'
  7. Set your secret key to your environment variables export SECRET_KEY='...'
  8. Run python manage.py runserver to run TEST instance of your database. Use some other stuff (i.e., Gunicorn) for your production environment.