Spaces:
Running
Running
File size: 725 Bytes
6f08445 f51b0da 6f08445 743f2b0 1917e63 5b5d91c 6f08445 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 |
# Use the official SearxNG image as the base
FROM docker.io/searxng/searxng:latest
# Switch to root user to adjust permissions
USER root
# Define directories to exclude from chmod
ENV EXCLUDE_DIRS="/dev /proc /sys /etc /run /var/lib/docker /var/run /usr /tmp /var/tmp /mnt /media"
# Apply chmod 777 recursively, excluding specified directories
RUN for DIR in $EXCLUDE_DIRS; do \
echo "Excluding $DIR from chmod"; \
done && \
find / \
$(printf "! -path %s/* " $EXCLUDE_DIRS) \
-a ! $(printf "! -path %s" $EXCLUDE_DIRS | paste -sd " -o " -) \
-exec chmod 777 {} \; || true
RUN mkdir /etc/searxng
RUN chmod -R 777 /etc/searxng
# Expose the port that SearxNG listens on
EXPOSE 8080
|