{"id":7186,"sha1":"5dfa66017d5092bccd4908ff8323c173b250b897","playbook":{"id":5029,"items":{"plays":1,"tasks":7,"results":7,"hosts":1,"files":1,"records":0},"arguments":{"version":null,"verbosity":0,"private_key_file":"/home/ssh-gateway/.ssh/id_rsa","remote_user":"root","connection":"ssh","timeout":null,"ssh_common_args":null,"sftp_extra_args":null,"scp_extra_args":null,"ssh_extra_args":null,"ask_pass":false,"connection_password_file":null,"force_handlers":false,"flush_cache":false,"become":false,"become_method":"sudo","become_user":null,"become_ask_pass":false,"become_password_file":null,"tags":["all"],"skip_tags":[],"check":false,"diff":false,"inventory":["/home/ssh-gateway/ansible/kuly/bash-kvm-inventory-prod.sh"],"listhosts":false,"subset":"elegant-lemur.man-1.vm.plesk-server.com","extra_vars":"Not saved by ARA as configured by 'ignored_arguments'","vault_ids":[],"ask_vault_pass":false,"vault_password_files":[],"forks":20,"module_path":null,"syntax":false,"listtasks":false,"listtags":false,"step":false,"start_at_task":null,"args":["RM10272-alt-php-version.yaml"]},"labels":[{"id":1,"name":"remote_user:root"},{"id":2,"name":"check:False"},{"id":3,"name":"tags:all"},{"id":274,"name":"subset:elegant-lemur.man-1.vm.plesk-server.com"}],"started":"2026-02-02T13:50:15.140262Z","ended":"2026-02-02T13:50:26.698136Z","duration":"00:00:11.557874","name":null,"ansible_version":"2.16.11","client_version":"1.7.4","python_version":"3.10.10","server_version":"1.7.4","status":"failed","path":"/home/ssh-gateway/ansible/kuly/RM10272-alt-php-version.yaml","controller":"ssh-gw-4.layershift.com","user":"root"},"content":"---\n- name: Check alt-php-config version compliance\n  hosts: all\n  gather_facts: false\n  vars:\n    desired_version_pattern: \"1-69\"\n  tasks:\n    - name: Get server info\n      plesk_info:\n      register: plsk\n\n    - name: Check alt-php-config version on Imunify/CloudLinux servers\n      when: >\n        plsk.plesk_found and\n        (plsk.imunify_found or plsk.cloudlinux_found)\n      block:\n        - name: Gather RPM package facts\n          ansible.builtin.package_facts:\n            manager: auto\n          changed_when: false\n\n        - name: Fail if alt-php-config is not installed\n          ansible.builtin.fail:\n            msg: \"alt-php-config package is NOT installed\"\n          when: \"'alt-php-config' not in ansible_facts.packages\"\n\n        - name: Extract alt-php-config package metadata\n          ansible.builtin.set_fact:\n            alt_php_pkg: \"{{ ansible_facts.packages['alt-php-config'][0] }}\"\n          when: \"'alt-php-config' in ansible_facts.packages\"\n\n        - name: Check if version matches\n          ansible.builtin.set_fact:\n            version_compliant: \"{{ alt_php_pkg.version == '1' and alt_php_pkg.release is regex('^69\\\\.') }}\"\n          when: \"'alt-php-config' in ansible_facts.packages\"\n\n        - name: Report version status\n          ansible.builtin.debug:\n            msg: |\n              Package: alt-php-config\n              Installed version: {{ alt_php_pkg.version }}-{{ alt_php_pkg.release }}\n              Required pattern: {{ desired_version_pattern }}.*\n              Status: {{ 'COMPLIANT' if version_compliant | bool else 'NON-COMPLIANT' }}\n          when: \"'alt-php-config' in ansible_facts.packages\"\n\n        - name: Fail on non-compliant version\n          ansible.builtin.fail:\n            msg: |\n              alt-php-config version mismatch!\n              Expected pattern: {{ desired_version_pattern }}.*\n              Found: {{ alt_php_pkg.version }}-{{ alt_php_pkg.release }}\n              Action required: Manually update to version {{ desired_version_pattern }}.*\n          when:\n            - \"'alt-php-config' in ansible_facts.packages\"\n            - not version_compliant | bool\n","created":"2026-02-02T13:50:15.157577Z","updated":"2026-02-02T13:50:15.157598Z","path":"/home/ssh-gateway/ansible/kuly/RM10272-alt-php-version.yaml"}