From 295f29dece1d62df46e02c4ae217d72eb42a5099 Mon Sep 17 00:00:00 2001 From: Hyperling Date: Thu, 21 Aug 2025 15:31:40 -0700 Subject: [PATCH] Do not check services if host is a Docker container. --- tasks/general/software/services.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tasks/general/software/services.yml b/tasks/general/software/services.yml index db2e34e..f55a4a2 100644 --- a/tasks/general/software/services.yml +++ b/tasks/general/software/services.yml @@ -9,6 +9,7 @@ pattern: "{{ crond_pattern }}" state: started enabled: yes + when: ansible_virtualization_type != 'docker' register: cron_status until: cron_status.state == "started" retries: 3 @@ -80,6 +81,7 @@ pattern: "{{ sshd_pattern }}" state: reloaded enabled: yes + when: ansible_virtualization_type != 'docker' register: sshd_status until: sshd_status.state == "started" retries: 3 @@ -113,6 +115,7 @@ pattern: "{{ ntp_server }}" state: started enabled: yes + when: ansible_virtualization_type != 'docker' register: ntp_status until: ntp_status.state == "started" retries: 3