diff --git a/Dockerfile b/Dockerfile index dea7f09..ac0f483 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,17 +1,19 @@ FROM python:3.14-slim -WORKDIR /app - # Copy application files + +WORKDIR /config +COPY scripts /. COPY config.py . COPY flairtimercomment.py . - +# Create App directory +RUN mkdir /app # Install dependencies RUN pip install --no-cache-dir praw ENV PYTHONUNBUFFERED=1 # Run the script -CMD ["python", "flairtimercomment.py"] +CMD ["sh", "/config/scripts/autorun.sh"] diff --git a/scripts/autorun.sh b/scripts/autorun.sh new file mode 100644 index 0000000..4c7ff29 --- /dev/null +++ b/scripts/autorun.sh @@ -0,0 +1,2 @@ +#!/bin/bash +copy.sh && start_bot.sh \ No newline at end of file diff --git a/scripts/start_bot.sh b/scripts/start_bot.sh new file mode 100644 index 0000000..7c5f57c --- /dev/null +++ b/scripts/start_bot.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +python3 app/flairtimercomment.py