forked from Symph0nia/CyberEdge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.backend
47 lines (41 loc) · 1.38 KB
/
Dockerfile.backend
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
FROM --platform=$TARGETPLATFORM ubuntu:22.04
WORKDIR /app
# 安装必要的工具
RUN apt-get update && \
apt-get install -y wget unzip nmap curl && \
rm -rf /var/lib/apt/lists/*
# 创建安装脚本
RUN echo '#!/bin/bash \n\
ARCH=$(uname -m) \n\
if [ "$ARCH" = "aarch64" ] || [ "$ARCH" = "arm64" ]; then \n\
ARCH="arm64" \n\
else \n\
ARCH="amd64" \n\
fi \n\
\n\
# 下载和安装 CyberEdge \n\
wget https://github.com/Symph0nia/CyberEdge/releases/download/v1.0.9/cyberedge-linux-${ARCH} -O cyberedge \n\
chmod +x cyberedge \n\
\n\
# 安装 httpx \n\
wget https://github.com/projectdiscovery/httpx/releases/download/v1.6.9/httpx_1.6.9_linux_${ARCH}.zip \n\
unzip httpx_1.6.9_linux_${ARCH}.zip \n\
mv httpx /usr/local/bin/ \n\
rm httpx_1.6.9_linux_${ARCH}.zip \n\
\n\
# 安装 subfinder \n\
wget https://github.com/projectdiscovery/subfinder/releases/download/v2.6.7/subfinder_2.6.7_linux_${ARCH}.zip \n\
unzip subfinder_2.6.7_linux_${ARCH}.zip \n\
mv subfinder /usr/local/bin/ \n\
rm subfinder_2.6.7_linux_${ARCH}.zip \n\
\n\
# 安装 ffuf \n\
wget https://github.com/ffuf/ffuf/releases/download/v2.1.0/ffuf_2.1.0_linux_${ARCH}.tar.gz \n\
tar xvf ffuf_2.1.0_linux_${ARCH}.tar.gz \n\
mv ffuf /usr/local/bin/ \n\
rm ffuf_2.1.0_linux_${ARCH}.tar.gz \n\
' > /app/install.sh && chmod +x /app/install.sh
# 执行安装脚本
RUN /app/install.sh
EXPOSE 31337
CMD ["./cyberedge", "-env", "prod"]