From 438db5ebebf9c84a2581da62ed4f1db454f1debd Mon Sep 17 00:00:00 2001 From: pacnpal <183241239+pacnpal@users.noreply.github.com> Date: Tue, 28 Jan 2025 14:35:16 -0500 Subject: [PATCH] feat(docker): create rules backup directory and configure volume for persistence --- Dockerfile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Dockerfile b/Dockerfile index 171aa97..f4531f5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,6 +22,10 @@ COPY . . # Install the package in editable mode RUN pip install -e . +# Create rules backup directory with proper permissions +RUN mkdir -p /app/rules_backup && \ + chmod 777 /app/rules_backup + # Default environment variables ENV ADGUARD_HOST="http://localhost" \ ADGUARD_PORT=3000 @@ -29,5 +33,8 @@ ENV ADGUARD_HOST="http://localhost" \ # Expose the application port EXPOSE 8000 +# Volume for persisting rules backups +VOLUME ["/app/rules_backup"] + # Command to run the application CMD ["python", "-m", "simpleguardhome.main"] \ No newline at end of file