Many dependencies are installed manually within the Dockerfiles, where Renovate cannot determine the version numbers by default. However, through custom matching, the corresponding data sources can be invoked, and the version number replaced via regex.
65 lines
2.1 KiB
Docker
65 lines
2.1 KiB
Docker
# renovate: datasource=github-tags depName=beancount packageName=beancount/beancount
|
|
ARG BEANCOUNT_VERSION=2.3.6
|
|
# renovate: datasource=github-tags depName=fava packageName=beancount/fava
|
|
ARG FAVA_VERSION=1.27.3
|
|
|
|
FROM node:20.17.0-slim as node_build_env
|
|
ARG FAVA_VERSION
|
|
|
|
RUN set -eux; \
|
|
apt-get update; \
|
|
apt-get install -y python3-babel git make;
|
|
|
|
RUN git clone --depth 1 --branch v${FAVA_VERSION} https://github.com/beancount/fava /tmp/build/fava
|
|
|
|
WORKDIR /tmp/build/fava
|
|
RUN set -eux; \
|
|
make -j $(nproc); \
|
|
rm -rf .*cache .eggs .tox build dist frontend/node_modules; \
|
|
find . -type f -name '*.py[c0]' -delete; \
|
|
find . -type d -name "__pycache__" -delete
|
|
|
|
FROM python:3.12.3-slim as build_env
|
|
ARG BEANCOUNT_VERSION
|
|
|
|
RUN set -eux; \
|
|
apt-get update; \
|
|
apt-get install -y build-essential libxml2-dev libxslt-dev curl git;
|
|
|
|
ENV PATH "/app/bin:$PATH"
|
|
RUN python -mvenv /app
|
|
COPY --from=node_build_env /tmp/build/fava /tmp/build/fava
|
|
|
|
RUN git clone --depth 1 --branch ${BEANCOUNT_VERSION} https://github.com/beancount/beancount /tmp/build/beancount
|
|
|
|
WORKDIR /tmp/build/beancount
|
|
RUN set -eux; \
|
|
CFLAGS=-s pip3 install -U /tmp/build/beancount; \
|
|
pip3 install -U /tmp/build/fava; \
|
|
pip3 install \
|
|
beancount-reds-plugins \
|
|
git+https://github.com/andreasgerstmayr/fava-dashboards.git \
|
|
git+https://github.com/beancount/beangrow.git \
|
|
git+https://github.com/redstreet/fava_investor.git \
|
|
git+https://github.com/daniel-wells/beancount_checkclosed.git \
|
|
git+https://github.com/PhracturedBlue/fava-portfolio-summary.git \
|
|
git+https://github.com/polarmutex/fava-envelope.git \
|
|
git+https://github.com/scauligi/refried.git \
|
|
git+https://github.com/beancount/beanprice.git@41576e2ac889e4825e4985b6f6c56aa71de28304 \
|
|
; \
|
|
pip3 uninstall -y pip; \
|
|
find /app -name __pycache__ -exec rm -rf -v {} +
|
|
|
|
FROM python:3.12.3-slim
|
|
COPY --from=build_env /app /app
|
|
|
|
# Default fava port number
|
|
EXPOSE 5000
|
|
|
|
ENV BEAN_ROOT ""
|
|
ENV BEANCOUNT_FILE ""
|
|
|
|
ENV FAVA_HOST "0.0.0.0"
|
|
ENV PATH "/app/bin:$PATH"
|
|
|
|
CMD ["fava"]
|