From 929c50b7b39a02b4f8db8b55957cfffe81c7ffa9 Mon Sep 17 00:00:00 2001 From: Karina5005 Date: Thu, 12 Oct 2023 15:27:48 +0300 Subject: [PATCH] fix: Dockerfile --- Dockerfile | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index ccb8068..c153b71 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,15 @@ FROM python:3.10 WORKDIR /backup + +ENV ACCESS_TOKEN="" +ENV ORGANIZATION="" + +RUN apt-get update && apt-get upgrade -y && \ + apt-get install -y git + +RUN mkdir "/backup/backup" +RUN mkdir "/backup/metrics" + RUN pip install backup-github-org==1.0.4 -ENTRYPOINT ["/usr/local/bin/backup-github", "--all", "-t", "$ACCESS_TOKEN", "-o", "./backup/", - "--metrics_path", "./metrics/${ORGANIZATION}_github_backup.prom", "$ORGANIZATION", ">", "./logs_${ORGANIZATION}.log"] + +ENTRYPOINT backup-github --all -t $ACCESS_TOKEN -o /backup/backup --metrics_path /backup/metrics/${ORGANIZATION}_github_backup.prom $ORGANIZATION