This commit is contained in:
12
Dockerfile
12
Dockerfile
@@ -19,9 +19,10 @@ COPY *config.json ./
|
||||
# Create output directories
|
||||
RUN mkdir -p /app/snapshots /app/logs
|
||||
|
||||
# Copy scheduler script
|
||||
# Copy scripts
|
||||
COPY scheduler.sh ./
|
||||
RUN chmod +x scheduler.sh
|
||||
COPY startup.sh ./
|
||||
RUN chmod +x scheduler.sh startup.sh
|
||||
|
||||
# Copy cron configuration
|
||||
COPY crontab /etc/cron.d/parentzone-downloader
|
||||
@@ -35,8 +36,11 @@ RUN touch /var/log/cron.log
|
||||
ENV PYTHONUNBUFFERED=1
|
||||
ENV PYTHONPATH=/app
|
||||
|
||||
# Expose port for web server
|
||||
EXPOSE 8080
|
||||
|
||||
# Expose volume for persistent data
|
||||
VOLUME ["/app/snapshots", "/app/logs", "/app/parentzone_images"]
|
||||
|
||||
# Start cron and keep container running
|
||||
CMD ["sh", "-c", "cron && tail -f /var/log/cron.log"]
|
||||
# Start all services using startup script
|
||||
CMD ["./startup.sh"]
|
||||
|
||||
Reference in New Issue
Block a user