Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

not creating job in /etc/logrotate.d/ #4

Open
kmkramer opened this issue Jun 2, 2017 · 0 comments
Open

not creating job in /etc/logrotate.d/ #4

kmkramer opened this issue Jun 2, 2017 · 0 comments

Comments

@kmkramer
Copy link

kmkramer commented Jun 2, 2017

I'm not able to get this formula to create a syslog job on RHEL or Ubuntu systems. I have even deleted /etc/logrotate.d/syslog from the system.

local:
----------
          ID: logrotate-pkg
    Function: pkg.installed
        Name: logrotate
      Result: True
     Comment: Package logrotate is already installed
     Started: 08:52:30.238854
    Duration: 572.55 ms
     Changes:
----------
          ID: logrotate-config
    Function: file.managed
        Name: /etc/logrotate.conf
      Result: True
     Comment: File /etc/logrotate.conf is in the correct state
     Started: 08:52:30.813396
    Duration: 159.144 ms
     Changes:
----------
          ID: logrotate-directory
    Function: file.directory
        Name: /etc/logrotate.d
      Result: True
     Comment: Directory /etc/logrotate.d is in the correct state
     Started: 08:52:30.972660
    Duration: 0.725 ms
     Changes:
----------
          ID: logrotate
    Function: service.running
        Name: crond
      Result: True
     Comment: The service crond is already running
     Started: 08:52:30.974377
    Duration: 24.126 ms
     Changes:

Summary for local
------------
Succeeded: 4
Failed:    0

corrected pillar example

logrotate:
  server:
    enabled: true
  job:
    syslog:
      files:
        - /var/log/cron
        - /var/log/maillog
        - /var/log/messages
        - /var/log/secure
        - /var/log/spooler
        - /var/log/slapd.log
        - /var/log/yum.log
      options:
        - daily
        - rotate 7
        - create 664 root root
        - sharedscripts
        - postrotate: "service syslog-ng restart >/dev/null 2>&1 || true"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant