Jamiiwej2903 commited on
Commit
1232def
·
verified ·
1 Parent(s): 4f5d5f0

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +48 -0
Dockerfile ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM zklcdc/go-bingai-pass:latest
2
+
3
+ ENV GBP_USER ${GBP_USER:-gbp}
4
+ ENV GBP_USER_ID ${GBP_USER_ID:-1000}
5
+
6
+ WORKDIR /app
7
+
8
+ USER root
9
+
10
+ RUN apt-get update && apt-get install -y --no-install-recommends curl jq
11
+
12
+ RUN curl -L https://github.com/Harry-zklcdc/go-proxy-bingai/releases/latest/download/go-proxy-bingai-linux-amd64.tar.gz -o go-proxy-bingai-linux-amd64.tar.gz && \
13
+ tar -zxvf go-proxy-bingai-linux-amd64.tar.gz && \
14
+ chmod +x go-proxy-bingai
15
+
16
+ RUN curl -L https://github.com/cloudflare/cloudflared/releases/latest/download/cloudflared-linux-amd64 -o cloudflared && \
17
+ chmod +x cloudflared
18
+
19
+ RUN bash -c "$(curl -L https://github.com/XTLS/Xray-install/raw/main/install-release.sh)" @ install && \
20
+ bash -c "$(curl -L wgcf-cli.vercel.app)" && \
21
+ wgcf-cli -r && \
22
+ wgcf-cli -g xray
23
+
24
+ COPY config.json /app/config.json
25
+
26
+ RUN TEMPLATE=$(jq -Rs . wgcf.json.xray.json | sed 's/^"//' | sed 's/"$//') && \
27
+ sed -i "s|{{TEMPLATE}}|${TEMPLATE}|g" config.json
28
+
29
+ RUN apt-get remove -y curl jq && \
30
+ apt-get clean && \
31
+ rm -rf /var/lib/apt/lists/* && \
32
+ rm go-proxy-bingai-linux-amd64.tar.gz
33
+
34
+ COPY supervisor.conf /etc/supervisor/conf.d/supervisor.conf
35
+
36
+ USER $GBP_USER
37
+
38
+ ENV PORT=7860
39
+ ENV BYPASS_SERVER=http://localhost:8080
40
+
41
+ ENV PROXY_SERVER=http://localhost:10808
42
+
43
+ ENV HTTP_PROXY=http://localhost:10808
44
+ ENV HTTPS_PROXY=http://localhost:10808
45
+
46
+ EXPOSE 7860
47
+
48
+ CMD /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisor.conf