|
|
@ -30,6 +30,7 @@ _install_caddy_service() { |
|
|
|
if ! wget https://raw.githubusercontent.com/caddyserver/caddy/master/dist/init/linux-systemd/caddy.service -O /lib/systemd/system/caddy.service; then |
|
|
|
if ! wget https://raw.githubusercontent.com/caddyserver/caddy/master/dist/init/linux-systemd/caddy.service -O /lib/systemd/system/caddy.service; then |
|
|
|
echo -e "$red 下载 caddy.service 失败!$none" && exit 1 |
|
|
|
echo -e "$red 下载 caddy.service 失败!$none" && exit 1 |
|
|
|
fi |
|
|
|
fi |
|
|
|
|
|
|
|
sed -i "s/-log-timestamps=false//g" /lib/systemd/system/caddy.service |
|
|
|
# # sed -i "s/www-data/root/g" /lib/systemd/system/caddy.service |
|
|
|
# # sed -i "s/www-data/root/g" /lib/systemd/system/caddy.service |
|
|
|
# sed -i "/on-abnormal/a RestartSec=3" /lib/systemd/system/caddy.service |
|
|
|
# sed -i "/on-abnormal/a RestartSec=3" /lib/systemd/system/caddy.service |
|
|
|
# sed -i "s/on-abnormal/always/" /lib/systemd/system/caddy.service |
|
|
|
# sed -i "s/on-abnormal/always/" /lib/systemd/system/caddy.service |
|
|
|