Update Dockerfile (#435)

This commit is contained in:
2026-01-18 08:40:38 -05:00
committed by GitHub
parent 2608a4e8db
commit 4d151aeb0c
2 changed files with 10 additions and 11 deletions

View File

@@ -1,12 +1,11 @@
# syntax=docker/dockerfile:1
FROM python:3.12-alpine3.17
FROM python:3.13-slim-trixie AS builder
WORKDIR /app
COPY pyproject.toml poetry.lock* ./
RUN pip install --no-cache-dir poetry==2.2.1 poetry-plugin-export && \
poetry export -f requirements.txt --without-hashes --output requirements.txt
RUN python -m venv /venv && \
/venv/bin/pip install --no-cache-dir -r requirements.txt
COPY . .
RUN pip install --no-cache-dir poetry==1.3.2 && \
poetry export -f requirements.txt > /tmp/requirements.txt && \
pip install -r /tmp/requirements.txt
ENTRYPOINT ["python", "/app/rfd_notify/cli.py", "-c", "config.yml"]
ENV PATH="/venv/bin:$PATH"
RUN apt-get purge -y --allow-remove-essential bash
ENTRYPOINT ["/venv/bin/python", "rfd_notify/cli.py", "-c", "config.yml"]

View File

@@ -13,7 +13,7 @@ This was originally written before [alerts](https://www.redflagdeals.com/alerts/
The simplest way to get started is to clone this repo, and run with docker:
```sh
docker run -it -v "$(pwd)/examples/config.yml:/app/config.yml" ghcr.io/davegallant/rfd-notify:2
docker run --rm -v "$(pwd)/examples/config.yml:/app/config.yml" $(docker build -q -t rfd-notify .)
```
To run the code with [poetry](https://python-poetry.org/), clone this repo and run the following: