1
0
Fork 0
A REST-API built with Flask and Python. Its main purpose is to receive the readings from the light meters welding booths in the Ritherdon factory and make them available for consumption by the relay-controllers in the gallery.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 

24 lines
564 B

from flask import Flask, render_template
import connexion
import config
from services import get_services
# The application instance.
app = config.connex_app
# The yml file configures the app's endpoints.
app.add_api("swagger.yml")
@app.route("/")
def home ():
data = get_services.get_latest_status_for_all_devices()
print(data)
return render_template("home.html", data=data)
@app.route("/robots.txt")
@app.route("/robots")
def robots():
return render_template("robots.txt")
if __name__ == "__main__":
app.run(host="0.0.0.0", debug=False)