Files
python/dockerfiles/with-uv/USAGE.md
T
nyeki c24ac43964 feat(with-uv:3.12-alpine): Create new image.
Create new `with-uv:3.12-alpine` image, restructure the folders, create a pushing script to make things easier.
2025-03-15 11:47:28 -03:00

22 lines
579 B
Markdown

# Usage
To optimize the building and pushing of your images, use the following template:
```dockerfile
# Use the image and tag you need.
FROM registry.nyeki.dev/docker/python/with-uv:3.13.2-alpine
# Only copy uv-related files, necessary for syncing and caching.
WORKDIR /app
COPY pyproject.toml uv.lock /app/
# Run with --no-dev on not to install dev dependencies.
RUN python3 -m uv sync --no-dev
# Copy the rest of your app.
COPY . /app/
# The ENTRYPOINT is set to `uv run --no-dev` by default, so only put your app's src directory as
# the command.
CMD [ "your_app" ]
```