1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-02-13 03:32:12 +00:00

Merge pull request #3162 from holta/iiab-remoteit_without_ansible

/use/bin/iiab-remoteit: Safer bounce of services, while deleting /etc/remoteit/config.json
This commit is contained in:
A Holt 2022-04-04 09:45:59 -04:00 committed by GitHub
commit efee271f00
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -34,16 +34,21 @@ if [[ $ans = "y" ]] || [[ $ans = "Y" ]]; then
# apt install & enable "latest" remote.it Device Package for your CPU/OS
curl -L https://downloads.remote.it/remoteit/install_agent.sh | sh
else
# 2022-04-04: Stop/Delete/Bounce sequence follows official suggestion here:
# https://support.remote.it/hc/en-us/articles/360061228252-Oops-I-cloned-an-SD-card-
echo -e "In a few secs, all 3 svcs {connectd, schannel, remoteit@...} should be back!\n"
systemctl stop connectd # Safer!
# '|| true' overrides 'bash -e' so script continues if config.json missing
mv /etc/remoteit/config.json /etc/remoteit/config.json.$(date +%F_%T_%Z) || true
echo -e "In just a few seconds, all 3 services should be enabled/started.\n"
systemctl restart connectd # Claim Code logic + kickstarts 2 svcs below
systemctl enable connectd # 2 enable lines, like enable-or-disable.yml
systemctl start connectd # Claim Code logic + kickstarts 2 svcs below
systemctl enable connectd # 2 enable lines, like enable-or-disable.yml
# schannel = "Remote tcp command service" started by connectd above if nec
systemctl enable schannel # 2 enable lines, like enable-or-disable.yml
systemctl enable schannel # 2 enable lines, like enable-or-disable.yml
# "Remote tcp connection service" appears a few seconds after connectd is
# started above. Auto-enabled when spawned by connectd, SO NOT NEC HERE: