Skip to content
Snippets Groups Projects
Verified Commit bda6c288 authored by Chris Croome's avatar Chris Croome
Browse files

Local facts removed

parent bb6b9185
No related branches found
No related tags found
1 merge request!1Merge Sury
Pipeline #26639 passed
# Copyright 2019-2023 Chris Croome
#
# This file is part of the Webarchitects PHP Ansible role.
#
# The Webarchitects PHP Ansible role is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
#
# The Webarchitects PHP Ansible role is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with the Webarchitects PHP Ansible role. If not, see <https://www.gnu.org/licenses/>.
---
- name: PHP local facts
block:
- name: Ansible facts.d directory present
ansible.builtin.file:
path: /etc/ansible/facts.d
recurse: true
state: directory
mode: "0755"
owner: root
group: root
- name: PHP phpquery modules local facts script in place
ansible.builtin.copy:
src: phpquery.fact.sh
dest: /etc/ansible/facts.d/phpquery.fact
owner: root
group: root
mode: "0755"
register: php_phpquery_local_facts_present
- name: Re-read Ansible local facts
ansible.builtin.setup:
filter: ansible_local
when: php_phpquery_local_facts_present.changed | bool
- name: Check that ansible_local facts are defined
ansible.builtin.assert:
that:
- ansible_local.phpquery is defined
quiet: "{% if ansible_verbosity == 0 %}true{% else %}false{% endif %}"
- name: Print Ansible local phpquery facts
ansible.builtin.debug:
var: ansible_local.phpquery
verbosity: "{% if ansible_check_mode | bool %}2{% else %}3{% endif %}"
when: ansible_local.phpquery is defined
tags:
- php
- php_cfg
- php_conf
- php_mods
...
......@@ -37,14 +37,6 @@
tags:
- php_apt
# - name: Include local fact tasks
# ansible.builtin.include_tasks: local_facts.yml
# when: ansible_local.phpquery is not defined
# tags:
# - php_cfg
# - php_conf
# - php_mods
- name: Include PHP variable check tasks
ansible.builtin.include_tasks: check_vars.yml
tags:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment