This commit is contained in:
mwiegand 2021-11-16 21:37:56 +01:00
parent 2802998afd
commit a978ec8cfb

View file

@ -6,8 +6,7 @@ from subprocess import check_output
app = Flask(__name__)
@app.route('/', methods = ['GET'])
def build():
strategy = request.args['strategy']
print(strategy, request.data)
@app.route('/<strategy>', methods=['POST'])
def build(strategy):
app.logger.info(str(request.data))
return check_output([f"/{environ['STRATEGIES_DIR']}/{strategy}", request.data])