Skip to content

Rename Dockerfile workdir - #11

Open
Vminoz wants to merge 1 commit into
astral-sh:mainfrom
Vminoz:main
Open

Rename Dockerfile workdir#11
Vminoz wants to merge 1 commit into
astral-sh:mainfrom
Vminoz:main

Conversation

@Vminoz

@Vminoz Vminoz commented Nov 16, 2025

Copy link
Copy Markdown

Follow-up on astral-sh/uv#16701

The fact that the main module of the app is at /app/app/main.py seems to have caused some confusion.

Would need an update in the related docs too.

Comment thread Dockerfile
Comment on lines +13 to +17
# Add created venv binaries to PATH
ENV PATH="/server/.venv/bin/:$PATH"

# Run the application.
CMD ["/app/.venv/bin/fastapi", "run", "app/main.py", "--port", "80"]
CMD ["fastapi", "run", "app/main.py", "--port", "80"]

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be changing this part? (I don't have strong feelings, but curious for the motivation)

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment thread Dockerfile

# Copy the application into the container.
COPY . /app
COPY . /server

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a best-practice name people use? /repo maybe?

@Vminoz Vminoz Nov 16, 2025

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usually /app 😄
But I've seen some images use /srv/some-name which I suppose is FHS-compliant although that's not a big deal for Docker containers

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants