16 lines
399 B
YAML
16 lines
399 B
YAML
|
#!/usr/bin/env ansible-playbook
|
||
|
# vim:ft=ansible:
|
||
|
---
|
||
|
- hosts: tags_zerotier
|
||
|
roles:
|
||
|
- role: zerotier
|
||
|
tags: [ zerotier ]
|
||
|
- hosts: all
|
||
|
tasks:
|
||
|
- name: disable zerotier when not tagged
|
||
|
systemd: name={{ item }} state=stopped enabled=no
|
||
|
with_items:
|
||
|
- zerotier-one.service
|
||
|
when: "'tags_zerotier' not in group_names and item in services"
|
||
|
tags: [ zerotier ]
|