From f3f19883f48975de043a0e5ab97ae641d7d82cb2 Mon Sep 17 00:00:00 2001 From: jtbx Date: Sun, 8 Dec 2024 19:27:26 +0100 Subject: [PATCH] feat(dokuwiki): Support Debian 12 --- playbooks/roles | 1 - roles/dokuwiki/defaults/main.yml | 1 + roles/dokuwiki/tasks/main.yml | 10 ---------- roles/dokuwiki/vars/main.yml | 4 ++++ 4 files changed, 5 insertions(+), 11 deletions(-) delete mode 120000 playbooks/roles create mode 100644 roles/dokuwiki/vars/main.yml diff --git a/playbooks/roles b/playbooks/roles deleted file mode 120000 index d8c4472..0000000 --- a/playbooks/roles +++ /dev/null @@ -1 +0,0 @@ -../roles \ No newline at end of file diff --git a/roles/dokuwiki/defaults/main.yml b/roles/dokuwiki/defaults/main.yml index 3406115..8358114 100644 --- a/roles/dokuwiki/defaults/main.yml +++ b/roles/dokuwiki/defaults/main.yml @@ -1,4 +1,5 @@ --- dokuwiki__installpath: "/var/www/dokuwiki" +dokuwiki__php_version: "{{ dokuwiki__php_versions[ansible_distribution + '-' + ansible_distribution_major_version] }}" dokuwiki__php_user: "www-data" dokuwiki__nginx_user: "nginx" diff --git a/roles/dokuwiki/tasks/main.yml b/roles/dokuwiki/tasks/main.yml index cd1bfd0..664f159 100644 --- a/roles/dokuwiki/tasks/main.yml +++ b/roles/dokuwiki/tasks/main.yml @@ -1,13 +1,3 @@ -- name: set php version to target - ansible.builtin.set_fact: - dokuwiki__php_version: '7.4' - when: dokuwiki__php_version is undefined and ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_major_version'] == "11" - -- name: set php version to target - ansible.builtin.set_fact: - dokuwiki__php_version: '8.2' - when: dokuwiki__php_version is undefined and ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_major_version'] == "12" - - name: Install php-fpm become: true ansible.builtin.apt: diff --git a/roles/dokuwiki/vars/main.yml b/roles/dokuwiki/vars/main.yml new file mode 100644 index 0000000..a7d7ca6 --- /dev/null +++ b/roles/dokuwiki/vars/main.yml @@ -0,0 +1,4 @@ +--- +dokuwiki__php_versions: + debian-11: "7.4" + debian-12: "8.2"