feat: deploy file

This commit is contained in:
archer
2023-05-05 15:00:52 +08:00
parent a34a2b622c
commit d1ee3913eb
8 changed files with 52 additions and 1 deletions

BIN
deploy/clash/Country.mmdb Normal file

Binary file not shown.

Binary file not shown.

22
deploy/clash/config.yaml Normal file
View File

@@ -0,0 +1,22 @@
mixed-port: 7890
allow-lan: false
bind-address: '*'
mode: rule
log-level: warning
dns:
enable: true
ipv6: false
nameserver:
- 8.8.8.8
- 8.8.4.4
cache-size: 400
proxies:
proxy-groups:
- { name: '♻️ 自动选择', type: url-test, proxies: [香港V02×1.5,ABC, 印度01, 台湾03, 新加坡02, 新加坡03, 日本01, 日本02, 新加坡01, 美国01, 美国02, 台湾01, 台湾02], url: 'https://api.openai.com', interval: 3600}
rules:
- 'DOMAIN-SUFFIX,google.com,♻️ 自动选择'
- 'DOMAIN-SUFFIX,ai.fastgpt.run,♻️ 自动选择'
- 'DOMAIN-SUFFIX,openai.com,♻️ 自动选择'
- 'DOMAIN-SUFFIX,api.openai.com,♻️ 自动选择'
- 'MATCH,DIRECT'

18
deploy/clash/proxy.sh Normal file
View File

@@ -0,0 +1,18 @@
export ALL_PROXY=socks5://127.0.0.1:7891
export http_proxy=http://127.0.0.1:7890
export https_proxy=http://127.0.0.1:7890
export HTTP_PROXY=http://127.0.0.1:7890
export HTTPS_PROXY=http://127.0.0.1:7890
OLD_PROCESS=$(pgrep clash)
if [ ! -z "$OLD_PROCESS" ]; then
echo "Killing old process: $OLD_PROCESS"
kill $OLD_PROCESS
fi
sleep 2
cd /root/fast-gpt/clash/fast
rm -f ./nohup.out || true
rm -f ./cache.db || true
nohup ./clash-linux-amd64-v3 -d ./ &
echo "Restart clash fast"

10
deploy/clash/stop.sh Normal file
View File

@@ -0,0 +1,10 @@
export ALL_PROXY=''
export http_proxy=''
export https_proxy=''
export HTTP_PROXY=''
export HTTPS_PROXY=''
OLD_PROCESS=$(pgrep clash)
if [ ! -z "$OLD_PROCESS" ]; then
echo "Killing old process: $OLD_PROCESS"
kill $OLD_PROCESS
fi

View File

@@ -52,7 +52,7 @@ services:
- /root/fast-gpt/pg/init.sql:/docker-entrypoint-initdb.d/init.sh
- /etc/localtime:/etc/localtime:ro
mongodb:
image: mongo:4.0.1
image: mongo:6.0.4
container_name: mongo
restart: always
ports:

Binary file not shown.

View File

@@ -0,0 +1 @@
sudo chmod +x /usr/local/bin/docker-compose