diff --git a/defaults/main.yml b/defaults/main.yml index 6c6a007..58d4491 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -9,6 +9,9 @@ apache_create_vhosts: true apache_vhosts_filename: "vhosts.conf" apache_vhosts_template: "vhosts.conf.j2" +# Additional packages to install on Debian/Ubuntu. +apache_packages_extra: [] + # On Debian/Ubuntu, a default virtualhost is included in Apache's configuration. # Set this to `true` to remove that default. apache_remove_default_vhost: false diff --git a/tasks/setup-Debian.yml b/tasks/setup-Debian.yml index b5d1412..32e338c 100644 --- a/tasks/setup-Debian.yml +++ b/tasks/setup-Debian.yml @@ -4,3 +4,8 @@ - name: Ensure Apache is installed on Debian. apt: "name={{ apache_packages }} state={{ apache_packages_state }}" + +- name: Ensure Apache packages are installed on Debian + apt: "name={{ package }} state={{ state }}" + with_items: "{{ apache_packages_extra }}" + when: apache_packages_extra is defined and apache_packages_extra | length > 0