Skip to content
Snippets Groups Projects
Commit 89a2ce98 authored by Ricy40's avatar Ricy40
Browse files

openshift main

parent c1c52ba9
No related branches found
No related tags found
No related merge requests found
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
from os import path
import os
from flask_login import LoginManager
from flask_cors import CORS
db = SQLAlchemy()
AM_DB = "database.db"
AM_DB = "alphamart"
def create_app():
app = Flask(__name__)
app.config['SECRET_KEY'] = 'AhAhAhAhAhAlphaMartYouReallyHaveNoIdeaWhatsInStoreForYou'
app.config['SQLALCHEMY_DATABASE_URI'] = f'sqlite:///{AM_DB}'
app.config['SQLALCHEMY_DATABASE_URI'] = f'mysql+pymysql://{os.environ["MYSQL"]}@csmysql.cs.cf.ac.uk:3306/c22003197_{AM_DB}'
db.init_app(app)
from .views import views
......
from AlphaMart import app as application
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment