mirror of
https://github.com/iiab/iiab.git
synced 2025-02-13 11:42:08 +00:00
Merge pull request #3167 from holta/remoteit-disable
Stop & Disable any remoteit@* services (via Ansible or iiab-remoteit-off)
This commit is contained in:
commit
4007612c2f
2 changed files with 22 additions and 14 deletions
|
@ -24,15 +24,22 @@
|
||||||
- schannel
|
- schannel
|
||||||
when: not remoteit_enabled
|
when: not remoteit_enabled
|
||||||
|
|
||||||
- name: Identify remoteit "Remote tcp connection service" unit file name, including uuid, e.g. remoteit@80:00:01:7F:7E:00:56:36.service
|
- name: Stop & Disable any remoteit@* services found in /etc/systemd/system/multi-user.target.wants/ e.g. remoteit@80:00:01:7F:7E:00:56:36.service
|
||||||
shell: ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@
|
shell: |
|
||||||
register: remoteit_service
|
systemctl stop $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@*)
|
||||||
|
systemctl disable $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@*)
|
||||||
ignore_errors: yes
|
ignore_errors: yes
|
||||||
|
when: not remoteit_enabled
|
||||||
|
|
||||||
- name: "Disable & Stop the actual service: {{ remoteit_service.stdout }}"
|
# - name: Identify remoteit "Remote tcp connection service" unit file name, including uuid, e.g. remoteit@80:00:01:7F:7E:00:56:36.service
|
||||||
systemd:
|
# shell: ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@
|
||||||
name: "{{ remoteit_service.stdout }}"
|
# register: remoteit_service
|
||||||
enabled: no
|
# ignore_errors: yes
|
||||||
state: stopped
|
|
||||||
when: not remoteit_enabled and remoteit_service.stdout != ""
|
# - name: "Disable & Stop the actual service: {{ remoteit_service.stdout }}"
|
||||||
ignore_errors: yes
|
# systemd:
|
||||||
|
# name: "{{ remoteit_service.stdout }}"
|
||||||
|
# enabled: no
|
||||||
|
# state: stopped
|
||||||
|
# when: not remoteit_enabled and remoteit_service.stdout != ""
|
||||||
|
# ignore_errors: yes
|
||||||
|
|
|
@ -26,7 +26,8 @@ systemctl stop schannel
|
||||||
systemctl disable schannel
|
systemctl disable schannel
|
||||||
|
|
||||||
# "Remote tcp connection service"
|
# "Remote tcp connection service"
|
||||||
systemctl stop $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@) || true
|
systemctl stop $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@*) || true
|
||||||
systemctl disable $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@) || true
|
systemctl disable $(ls /etc/systemd/system/multi-user.target.wants/ | grep remoteit@*) || true
|
||||||
# Its systemd service name (e.g. remoteit@80:00:01:7F:7E:00:56:36.service)
|
# FYI these systemd service names e.g. remoteit@80:00:01:7F:7E:00:56:36.service
|
||||||
# changes when a new claim code is generated!
|
# change, and arise when a new claim code is generated, when the IIAB device is
|
||||||
|
# registed, etc. 2022-04-05 Example: https://github.com/iiab/iiab/issues/3166
|
||||||
|
|
Loading…
Reference in a new issue