Merge pull request #408 from KiweeEu/feature/do-not-run-php-fpm-in-check-mode

Do not run php-fpm service when ansible is in check mode
This commit is contained in:
Jeff Geerling 2023-06-21 22:27:57 -05:00 committed by GitHub
commit 2d4501688a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -13,3 +13,4 @@
when:
- php_enable_php_fpm
- php_fpm_state == 'started'
- not ansible_check_mode

View File

@ -50,4 +50,7 @@
name: "{{ php_fpm_daemon }}"
state: "{{ php_fpm_state }}"
enabled: "{{ php_fpm_enabled_on_boot }}"
when: php_enable_php_fpm and ansible_distribution != "Debian"
when:
- php_enable_php_fpm
- ansible_distribution != "Debian"
- not ansible_check_mode