Hi, I'm following this example that shows how to run flask-ngrok using Google Colab (from medium)
!pip install flask-ngrok
from flask_ngrok import run_with_ngrok
from flask import Flask
app = Flask(__name__)
run_with_ngrok(app) #starts ngrok when the app is run
@app.route("/")
def home():
return "<h1>Running Flask on Google Colab!</h1>"
app.run()
Everything runs fine, but is there a way I can get the public URL that the app is running on as a variable? I need to pass the URL to another cell and I would prefer to not to have to copy/paste it.
Hi, I'm following this example that shows how to run flask-ngrok using Google Colab (from medium)
Everything runs fine, but is there a way I can get the public URL that the app is running on as a variable? I need to pass the URL to another cell and I would prefer to not to have to copy/paste it.