#!/bin/bash cd /etc/soga || { echo "Failed to change directory to /etc/soga"; exit 1; } if rm -rf blockList; then echo 'Successfully deleted blockList' if wget https://up.mf-api1.site/yunwei01/blockList; then echo 'Successfully downloaded blockList' else echo 'Failed to download blockList' fi else echo 'Failed to delete blockList' fi if rm -rf dns.yml; then echo 'Successfully deleted dns.yml' if wget https://up.mf-api1.site/yunwei01/dns.yml; then echo 'Successfully downloaded dns.yml' else echo 'Failed to download dns.yml' fi else echo 'Failed to delete dns.yml' fi if rm -rf soga-hy2.conf; then echo 'Successfully deleted soga-hy2.conf' if wget https://up.mf-api1.site/yunwei01/soga-hy2.conf; then echo 'Successfully downloaded soga-hy2.conf' else echo 'Failed to download soga-hy2.conf' fi else echo 'Failed to delete soga-hy2.conf' fi if rm -rf soga.conf; then echo 'Successfully deleted soga.conf' if wget https://up.mf-api1.site/yunwei01/soga.conf; then echo 'Successfully downloaded soga.conf' else echo 'Failed to download soga.conf' fi else echo 'Failed to delete soga.conf' fi if rm -rf v2ray.crt; then echo 'Successfully deleted v2ray.crt' if wget https://up.mf-api1.site/yunwei01/v2ray.crt; then echo 'Successfully downloaded v2ray.crt' else echo 'Failed to download v2ray.crt' fi else echo 'Failed to delete v2ray.crt' fi if rm -rf v2ray.key; then echo 'Successfully deleted v2ray.key' if wget https://up.mf-api1.site/yunwei01/v2ray.key; then echo 'Successfully downloaded v2ray.key' else echo 'Failed to download v2ray.key' fi else echo 'Failed to delete v2ray.key' fi apt-get install supervisor -y systemctl enable supervisor systemctl start supervisor # 下载配置文件到 /etc/supervisor/conf.d/ #wget -O /etc/supervisor/conf.d/soga-hy2.conf https://up.mf-api1.site/soga-hy2.conf #wget -O /etc/supervisor/conf.d/soga-trojan.conf https://up.mf-api1.site/soga-trojan.conf #wget -O /etc/supervisor/conf.d/soga-v2ray.conf https://up.mf-api1.site/soga-v2ray.conf # 更新 supervisor 配置并重新加载 supervisorctl update supervisorctl reload