From adc93298eb21907b5192b318104bab69a0d77ffa Mon Sep 17 00:00:00 2001 From: michivonah Date: Sun, 7 Jan 2024 20:59:34 +0100 Subject: [PATCH] create docker image --- Dockerfile | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..d0141d5 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,26 @@ +# AdGuard Home - Add DDNS IP as allowed client - Docker Container +# Michi von Ah - January 2024 + +FROM python:3.12 + +# Create directory +RUN mkdir app +WORKDIR /app/ + +# Copy files +COPY main.py . +COPY requirements.txt . + +# Set enviromental variables +ENV API_BASE_URL "https://example.com" +ENV API_USERNAME "YOUR_USERNAME" +ENV API_PASSWORD "YOUR_PASSWORD" +ENV DOMAIN_NAME "example.com" + +# Install needed packages +RUN pip3 install --upgrade pip +RUN pip3 install pipenv +RUN pip install --no-cache-dir -r requirements.txt + +# Run script +CMD ["python3","main.py"] \ No newline at end of file