mirror of
https://github.com/ComputerScienceHouse/proxstar.git
synced 2025-03-09 15:40:09 +00:00
Use Redis to link VNC tokens to VMID
This commit is contained in:
parent
aa1c4834f4
commit
433c845a35
4 changed files with 22 additions and 7 deletions
|
|
@ -6,6 +6,7 @@ import psycopg2
|
|||
import requests
|
||||
from flask import Flask
|
||||
from rq import get_current_job
|
||||
from redis import Redis
|
||||
from sqlalchemy import create_engine
|
||||
from sqlalchemy.orm import sessionmaker
|
||||
|
||||
|
|
@ -32,7 +33,6 @@ else:
|
|||
config = os.path.join(app.config.get('ROOT_DIR', os.getcwd()), 'config.py')
|
||||
app.config.from_pyfile(config)
|
||||
|
||||
|
||||
def connect_db():
|
||||
engine = create_engine(app.config['SQLALCHEMY_DATABASE_URI'])
|
||||
Base.metadata.bind = engine
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue