Skip to content

Instantly share code, notes, and snippets.

@devinnasar
Created February 27, 2018 21:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save devinnasar/a7397cde946880e6ca74db9f91bb9487 to your computer and use it in GitHub Desktop.
Save devinnasar/a7397cde946880e6ca74db9f91bb9487 to your computer and use it in GitHub Desktop.
This fails when the string actually isn't in the file
freshclam_confirm_sysconfig_exists:
file.exists:
- name: {{ freshclam.sysconfig_path }}/freshclam
freshclam_enable_cron_script:
file.comment:
- name: {{ freshclam.sysconfig_path }}/freshclam
- regex: 'FRESHCLAM_DELAY=disabled-warn'
- char: '#'
- require:
- file: freshclam_confirm_sysconfig_exists
@devinnasar
Copy link
Author


      ID: freshclam_enable_cron_script
Function: file.comment
    Name: /etc/sysconfig/freshclam
  Result: False
 Comment: FRESHCLAM_DELAY=disabled-warn: Pattern not found
 Started: 16:17:45.800136
Duration: 1.7 ms
 Changes:   

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment