File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -30,9 +30,19 @@ RUN mkdir -p /config/settings \
3030 && chmod -R 755 /config
3131
3232# Create a proper entrypoint script to handle initialization
33- RUN echo '#!/bin/sh\n \
34- # Ensure config permissions are correct on container restart\n if [ ! -f /config/.initialized ]; then\n echo "Initializing Huntarr config directory..."\n chown -R 1000:1000 /config\n chmod -R 755 /config\n touch /config/.initialized\n fi\n\n # Run the main application\n exec python3 /app/main.py\n ' > /app/entrypoint.sh \
35- && chmod +x /app/entrypoint.sh
33+ RUN echo '#!/bin/sh' > /app/entrypoint.sh && \
34+ echo '' >> /app/entrypoint.sh && \
35+ echo '# Ensure config permissions are correct on container restart' >> /app/entrypoint.sh && \
36+ echo 'if [ ! -f /config/.initialized ]; then' >> /app/entrypoint.sh && \
37+ echo ' echo "Initializing Huntarr config directory..."' >> /app/entrypoint.sh && \
38+ echo ' chown -R 1000:1000 /config' >> /app/entrypoint.sh && \
39+ echo ' chmod -R 755 /config' >> /app/entrypoint.sh && \
40+ echo ' touch /config/.initialized' >> /app/entrypoint.sh && \
41+ echo 'fi' >> /app/entrypoint.sh && \
42+ echo '' >> /app/entrypoint.sh && \
43+ echo '# Run the main application' >> /app/entrypoint.sh && \
44+ echo 'exec python3 /app/main.py' >> /app/entrypoint.sh && \
45+ chmod +x /app/entrypoint.sh
3646
3747# Set environment variables
3848ENV PYTHONPATH=/app
You can’t perform that action at this time.
0 commit comments