aboutsummaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile31
1 files changed, 31 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..2264a95
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,31 @@
+# hadolint ignore=DL3007
+FROM debian:latest
+
+WORKDIR /home/fava
+
+# hadolint ignore=DL3008,DL3013
+RUN \
+ export DEBIAN_FRONTEND=noninteractive && \
+ groupadd -g 1000 fava && \
+ adduser \
+ --uid 1000 \
+ --gid 1000 \
+ --home /home/fava \
+ --no-create-home fava && \
+ chown -R fava:fava /home/fava && \
+ apt-get update && \
+ apt-get install --no-install-recommends -y \
+ beancount \
+ ledger \
+ ledger2beancount \
+ python3-pip && \
+ rm -rf /var/lib/apt/lists/* && \
+ pip3 install \
+ --break-system-packages \
+ --no-cache-dir \
+ fava
+
+COPY --chown=fava src/init.sh /home/fava/init.sh
+COPY --chown=fava src/.ledger2beancount.yaml /home/fava/.ledger2beancount.yaml
+USER fava
+ENTRYPOINT [ "bash", "/home/fava/init.sh" ]