From 6a989b6007ee78deabc379a165ad3a69d0a701df Mon Sep 17 00:00:00 2001 From: Geno Date: Fri, 19 Mar 2021 09:48:59 +0100 Subject: [PATCH] create default variables, first step for ubuntu support --- defaults/main.yml | 4 +++- tasks/php.yml | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/defaults/main.yml b/defaults/main.yml index 0aeb01e..acc3bac 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -1,4 +1,6 @@ --- # webserver_dehydrated_email: "" # required -webserver_php_enabled: False webserver_tls_enabled: True +webserver_php_enabled: False +webserver_php_ini: /etc/php/php.ini +webserver_php_service: "php-fpm.service" diff --git a/tasks/php.yml b/tasks/php.yml index 2632b16..ba84a5e 100644 --- a/tasks/php.yml +++ b/tasks/php.yml @@ -13,7 +13,7 @@ - name: enable extension notify: restart php-fpm lineinfile: - path: /etc/php/php.ini + path: '{{ webserver_php_ini }}' regexp: ';extension={{ item }}' line: "extension={{ item }}" with_items: @@ -32,7 +32,7 @@ - name: enabled and started php-fpm systemd: - name: php-fpm + name: "{{ webserver_php_service }}" enabled: yes state: started