Execution
Date 15 Jan 2025 13:08:49 +0000
Duration 00:02:49.60
Controller ssh-gw-4.layershift.com
User root
Versions
Ansible 2.16.11
ara 1.7.2 / 1.7.2
Python 3.10.10
Summary
334 Hosts
3 Tasks
1002 Results
1 Plays
1 Files
0 Records

File: /home/ssh-gateway/ansible/kuly/test1.yaml

---
- name: Test Plesk Info Module
  hosts: all
  tasks:
    - name: Check Plesk binary and version
      plesk_info:
      register: plsk
    - name: Check if server is CloudLinux
      when: plsk.cloudlinux_found
      block:
        - name: Print it
          ansible.builtin.debug:
            msg: "This is cloudlinux"
          changed_when: plsk.cloudlinux_found
        - name: List file
          ansible.builtin.shell: |
            set -o pipefail
            ls -la /usr/local/psa/var/root.event_handler.lock
            plesk bin event_handler --list
          args:
            executable: /bin/bash
          changed_when: plsk.cloudlinux_found