Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

175
Views
how to get fastapi docs work with docker container deployed in aks?

test endpoint which is working : baseurl/ds-clm-metadata-aks/test

OpenAPI valid json : baseurl/ds-clm-metadata-aks/openapi.json

Local container run is working : localhost:4557/docs, localhost:4557/docs

ideally docs should be rendered at : baseurl/ds-clm-metadata-aks/docs

But gives the following error : enter image description here

Redoc url : baseurl/ds-clm-metadata-aks/redoc , gives error: enter image description here

"""This package contains functions for metadata attribute extraction"""
from fastapi import FastAPI, Request

app = FastAPI()


@app.get("/test")
async def index(request: Request):
    return {"Api is running"}
  
import uvicorn

from dsclm.metadata import endpoints


if __name__ == "__main__":
    uvicorn.run("dsclm.metadata:app", host='0.0.0.0', port=4558,
                reload=True, debug=True, workers=3)
over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

I can see what's going on. You forgot to set the "root_path" parameter, either to Uvicorn or in FastAPI app constructor. And this raises what you can see.

Please adjust the "root_path" either in Uvicorn part (recommended) or in FastAPI part (drawback). Read this for full explanations : https://fastapi.tiangolo.com/advanced/behind-a-proxy

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!