Update dockerfile
This commit is contained in:
@@ -19,6 +19,9 @@ RUN pip install --no-cache-dir -r requirements.txt
|
|||||||
# Copy the rest of the application
|
# Copy the rest of the application
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
|
# Create directories for persistent storage
|
||||||
|
RUN mkdir -p /data/logs
|
||||||
|
|
||||||
# Create a non-root user and switch to it
|
# Create a non-root user and switch to it
|
||||||
RUN useradd -m botuser && chown -R botuser:botuser /app
|
RUN useradd -m botuser && chown -R botuser:botuser /app
|
||||||
USER botuser
|
USER botuser
|
||||||
@@ -28,4 +31,4 @@ ENV PYTHONUNBUFFERED=1
|
|||||||
ENV CONFIG_PATH=/app/config.ini
|
ENV CONFIG_PATH=/app/config.ini
|
||||||
|
|
||||||
# Command to run the bot
|
# Command to run the bot
|
||||||
CMD ["python", "pterodisbot.py"]
|
CMD ["sh", "-c", "python generate_config.py && python pterodisbot.py"]
|
Reference in New Issue
Block a user