Skip to content

Commit ea5b173

Browse files
fix: set correct port and startup config for azure
1 parent 35ffba3 commit ea5b173

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

app.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
1-
from flask import Flask, render_template
1+
import os
2+
from flask import Flask
23

34
app = Flask(__name__)
45

5-
@app.route("/")
6-
def home () :
7-
return render_template("index.html")
6+
@app.route('/')
7+
def home():
8+
return "Hello from Ray on Azure!"
89

9-
if __name__ == "__main__":
10-
app.run(debug=True)
10+
if __name__ == '__main__':
11+
port = int(os.environ.get("PORT", 8080)) # Default to 8080
12+
app.run(host='0.0.0.0', port=port)

0 commit comments

Comments
 (0)