summaryrefslogtreecommitdiffstats
path: root/roles/nickhammond.logrotate/tasks/main.yml
diff options
context:
space:
mode:
authorTroy Dawson <tdawson@redhat.com>2015-08-27 15:23:44 -0500
committerTroy Dawson <tdawson@redhat.com>2015-08-27 15:23:44 -0500
commitede0fd9a75f3f0927f95cf542be0cb4a9448c96d (patch)
treed630e3f95ce950fbbfe664075048d63d3278c51d /roles/nickhammond.logrotate/tasks/main.yml
parent2483b7767d4e56e41e9890adfffe4bdc1480a11b (diff)
parentf0d03d257f2186c91e99c06e34be737468ea6ad6 (diff)
downloadopenshift-ede0fd9a75f3f0927f95cf542be0cb4a9448c96d.tar.gz
openshift-ede0fd9a75f3f0927f95cf542be0cb4a9448c96d.tar.bz2
openshift-ede0fd9a75f3f0927f95cf542be0cb4a9448c96d.tar.xz
openshift-ede0fd9a75f3f0927f95cf542be0cb4a9448c96d.zip
Merge pull request #518 from tdawson/201508logrotate
Update syslog logrotate to compress and rotate daily
Diffstat (limited to 'roles/nickhammond.logrotate/tasks/main.yml')
-rw-r--r--roles/nickhammond.logrotate/tasks/main.yml10
1 files changed, 10 insertions, 0 deletions
diff --git a/roles/nickhammond.logrotate/tasks/main.yml b/roles/nickhammond.logrotate/tasks/main.yml
new file mode 100644
index 000000000..fda23e05e
--- /dev/null
+++ b/roles/nickhammond.logrotate/tasks/main.yml
@@ -0,0 +1,10 @@
+---
+- name: nickhammond.logrotate | Install logrotate
+ action: "{{ansible_pkg_mgr}} pkg=logrotate state=present"
+
+- name: nickhammond.logrotate | Setup logrotate.d scripts
+ template:
+ src: logrotate.d.j2
+ dest: /etc/logrotate.d/{{ item.name }}
+ with_items: logrotate_scripts
+ when: logrotate_scripts is defined