WARNING: This is a development server. Do not use it in a production deployment.
Use a production WSGI server instead
from flask import Flask, render_template
from threading import Thread
app = Flask(__name__)
@app.route('/')
def index():
return "Alive"
def run():
app.run(host='0.0.0.0',port=8080)
def keep_alive():
t = Thread(target=run)
t.start()
New contributor
Nobody Knows is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.