23 lines
446 B
YAML
23 lines
446 B
YAML
---
|
|
- name: "uninstall Apache"
|
|
hosts: debian_family
|
|
|
|
tasks:
|
|
- name: "stop Apache"
|
|
become: yes
|
|
ansible.builtin.service:
|
|
name: apache2
|
|
state: stopped
|
|
|
|
- name: "Remove Apache"
|
|
become: yes
|
|
ansible.builtin.apt:
|
|
name: "apache2"
|
|
state: "absent"
|
|
|
|
- name: "Delete index.html"
|
|
become: yes
|
|
ansible.builtin.file:
|
|
path: /var/www/html/index.html
|
|
state: absent
|