Skip to content

Instantly share code, notes, and snippets.

@kaustubhgupta
Last active December 30, 2021 16:42
Show Gist options
  • Save kaustubhgupta/deee83edd63613ca9218636bb7abb260 to your computer and use it in GitHub Desktop.
Save kaustubhgupta/deee83edd63613ca9218636bb7abb260 to your computer and use it in GitHub Desktop.
from fastapi import FastAPI
from config import Settings
import uvicorn
setting = Settings()
app = FastAPI(openapi_url=setting.openapi_url)
@app.get('/')
def index():
return "Hello: {}".format(setting.appName)
if __name__ == "__main__":
uvicorn.run("fastapi_config:app", host='127.0.0.1', port=8000, reload=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment