zyxciss commited on
Commit
8cff1e7
·
verified ·
1 Parent(s): 7c7eb80

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +26 -0
Dockerfile ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use a lightweight Python base image
2
+ FROM python:3.10-slim
3
+
4
+ # Set environment variables for non-root execution
5
+ ENV PIP_NO_CACHE_DIR=off \
6
+ PIP_DISABLE_PIP_VERSION_CHECK=on
7
+
8
+ # Install dependencies
9
+ RUN apt-get update && apt-get install -y --no-install-recommends \
10
+ git curl build-essential \
11
+ && rm -rf /var/lib/apt/lists/*
12
+
13
+ # Set working directory
14
+ WORKDIR /app
15
+
16
+ # Clone SearXNG repository
17
+ RUN git clone --depth 1 https://github.com/searxng/searxng.git .
18
+
19
+ # Install Python dependencies
20
+ RUN pip install --no-cache-dir -r requirements.txt
21
+
22
+ # Expose the default SearXNG port
23
+ EXPOSE 7860
24
+
25
+ # Run SearXNG
26
+ CMD ["python", "searx/webapp.py"]