Update syncthing-install.sh

This commit is contained in:
Michel Roegl-Brunner 2024-12-18 14:30:55 +01:00 committed by GitHub
parent 13afe3d289
commit e6faaf41b7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -28,7 +28,11 @@ $STD apt-get install -y syncthing
$STD systemctl enable syncthing@root.service $STD systemctl enable syncthing@root.service
systemctl start syncthing@root.service systemctl start syncthing@root.service
sleep 5 sleep 5
sed -i "{s/127.0.0.1:8384/0.0.0.0:8384/g}" /root/.config/syncthing/config.xml if [ -f "/root/.local/state/syncthing/config.xml" ]; then
sed -i "s/127.0.0.1:8384/0.0.0.0:8384/g" /root/.local/state/syncthing/config.xml
elif [ -f "/root/.config/syncthing/config.xml" ]; then
sed -i "s/127.0.0.1:8384/0.0.0.0:8384/g" /root/.config/syncthing/config.xml
fi
systemctl restart syncthing@root.service systemctl restart syncthing@root.service
msg_ok "Installed Syncthing" msg_ok "Installed Syncthing"