Remove snap

This commit is contained in:
Przemek Grondek 2022-08-25 23:15:00 +02:00
parent e7c3e1eed2
commit e8836162eb
2 changed files with 21 additions and 0 deletions

View File

@ -2,3 +2,5 @@
- import_tasks: cleanup.yml - import_tasks: cleanup.yml
- import_tasks: timezone.yml - import_tasks: timezone.yml
- import_tasks: snap.yml

View File

@ -0,0 +1,19 @@
---
- become: yes
block:
- name: Get the list of services
service_facts:
- name: stop snapd
systemd:
name: snapd
state: stopped
when: "'snapd.service' in services"
- name: uninstall snapd
apt:
update_cache: yes
state: absent
purge: yes
pkg:
- snapd