forked from Eslamanwar/red-cell
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
66 lines (56 loc) · 1.97 KB
/
Dockerfile
File metadata and controls
66 lines (56 loc) · 1.97 KB
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
FROM vxcontrol/kali-linux:latest
WORKDIR /app
# Install Python and essential tools
RUN apt-get update && apt-get install -y \
python3 \
python3-venv \
python3-pip \
git \
curl \
# Pentesting tools (already in Kali, but ensure they're installed)
nmap \
subfinder \
nuclei \
httpx-toolkit \
metasploit-framework \
sqlmap \
nikto \
dirb \
gobuster \
wfuzz \
hydra \
john \
hashcat \
aircrack-ng \
wireshark-common \
tcpdump \
netcat-traditional \
socat \
&& rm -rf /var/lib/apt/lists/*
# Install katana (web crawler for AI-driven analysis)
RUN go install github.com/projectdiscovery/katana/cmd/katana@latest 2>/dev/null || \
(curl -sL https://github.com/projectdiscovery/katana/releases/latest/download/katana_linux_amd64.zip -o /tmp/katana.zip && \
unzip /tmp/katana.zip -d /usr/local/bin/ && rm /tmp/katana.zip) || \
echo "Katana installation failed - will use fallback crawling"
# Download and update nuclei templates during build
# Ensure templates are in /root/nuclei-templates for the scanning activities
RUN nuclei -update-templates -silent || true && \
# Check where templates were installed and create symlink if needed
if [ -d "/root/.local/nuclei-templates" ] && [ ! -d "/root/nuclei-templates" ]; then \
ln -s /root/.local/nuclei-templates /root/nuclei-templates; \
fi && \
echo "Nuclei templates installed at:" && ls -la /root/nuclei-templates 2>/dev/null || ls -la /root/.local/nuclei-templates 2>/dev/null || echo "Templates location unknown"
# Create python symlink if needed
RUN ln -sf /usr/bin/python3 /usr/bin/python || true
# Upgrade pip
RUN python3 -m pip install --upgrade pip
# Copy project files
COPY pyproject.toml ./
COPY project ./project
# Install Python dependencies
RUN pip install --no-cache-dir -e .
# Set environment variables
ENV PYTHONUNBUFFERED=1
ENV PATH="/usr/local/bin:${PATH}"
# Run the worker
CMD ["python", "-m", "project.run_worker"]