ykl45 commited on
Commit
73749f6
·
verified ·
1 Parent(s): 9743765

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +0 -14
Dockerfile CHANGED
@@ -4,19 +4,5 @@ RUN apt install -y git
4
  RUN git clone https://github.com/renqabs/notdiamond2api.git /app
5
  WORKDIR app
6
  RUN pip install -r requirements.txt
7
- ENV DNS_SERVER1=8.8.8.8
8
- ENV DNS_SERVER2=8.8.4.4
9
- RUN mkdir -p /etc/docker-dns
10
- RUN echo '#!/bin/bash\n\
11
- echo "nameserver $DNS_SERVER1" > /etc/docker-dns/resolv.conf\n\
12
- echo "nameserver $DNS_SERVER2" >> /etc/docker-dns/resolv.conf\n\
13
- mount --bind /etc/docker-dns/resolv.conf /etc/resolv.conf\n\
14
- echo "DNS configuration completed:"\n\
15
- cat /etc/resolv.conf\n\
16
- exec "$@"' > /usr/local/bin/docker-entrypoint.sh && \
17
- chmod +x /usr/local/bin/docker-entrypoint.sh
18
-
19
- # 设置入口点
20
- ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]
21
  EXPOSE 7860
22
  CMD ["python", "app.py"]
 
4
  RUN git clone https://github.com/renqabs/notdiamond2api.git /app
5
  WORKDIR app
6
  RUN pip install -r requirements.txt
 
 
 
 
 
 
 
 
 
 
 
 
 
 
7
  EXPOSE 7860
8
  CMD ["python", "app.py"]