Skip to content

fastapi: Modernize Dockerfile to python:3.11-slim and clean up deprecated dev-envs #823

Description

@VimalN2005

Summary

While going through the fastapi sample, I noticed a few areas that could be modernized:

  1. It uses tiangolo/uvicorn-gunicorn-fastapi:python3.9-slim, which has been deprecated upstream in favor of official Python slim images.
  2. The Dockerfile contains a remaining FROM builder as dev-envs stage that is no longer needed since Dev Environments was sunset.
  3. The README.md references the legacy docker-compose command instead of Compose V2 syntax (docker compose).

Proposal

  • Update the Dockerfile to use standard python:3.11-slim with uvicorn[standard].
  • Remove the unused dev-envs stage and clean up compose.yaml.
  • Update the README commands to Compose V2.

Question for Maintainers

Would the team be open to this modernization? If so, could you please assign this issue to me? I'll be glad to prepare and submit the PR.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions