From 0c75ba406cb8df784a97cc76f2d886be65b3a748 Mon Sep 17 00:00:00 2001 From: Corbin Bartsch Date: Sun, 10 Apr 2022 22:41:08 -0400 Subject: [PATCH] Remove Apache2 package when using nginx to avoid clashing --- tasks/packages.yaml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/tasks/packages.yaml b/tasks/packages.yaml index fa7be4a..d24226a 100644 --- a/tasks/packages.yaml +++ b/tasks/packages.yaml @@ -5,12 +5,24 @@ state: present when: not nextcloud_nginx +- name: Remove nginx package + ansible.builtin.package: + name: nginx + state: absent + when: not nextcloud_nginx + - name: Ensure nginx package is installed ansible.builtin.package: name: nginx state: present when: nextcloud_nginx +- name: Remove Apache2 package + ansible.builtin.package: + name: apache2 + state: absent + when: nextcloud_nginx + - name: Ensure PHP package is installed ansible.builtin.package: name: php