add base web + change a container

This commit is contained in:
M1n-0
2025-04-14 10:48:11 +02:00
parent 7a7ad1e59d
commit 17c91e5fa4
5 changed files with 52 additions and 28 deletions

17
web/app.py Normal file
View File

@@ -0,0 +1,17 @@
# flask-app/app.py
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
from flask import render_template
app = Flask(__name__)
app.config['SQLALCHEMY_DATABASE_URI'] = 'mysql+pymysql://flaskuser:flaskpass@mariadb/flaskdb'
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
db = SQLAlchemy(app)
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0')