1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00

AWStats OS clarifs in Ansible output

This commit is contained in:
A Holt 2017-11-10 15:33:19 -05:00 committed by GitHub
parent 0a2198dbed
commit ef63e6e356
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -8,7 +8,7 @@
tags: tags:
- download - download
- name: Install AWStats package - name: Install AWStats package (debuntu)
package: name={{ item }} package: name={{ item }}
state=present state=present
with_items: with_items:
@ -18,7 +18,7 @@
tags: tags:
- download - download
- name: enable cgi execution - name: enable cgi execution (debuntu)
command: a2enmod cgi command: a2enmod cgi
when: is_debuntu when: is_debuntu
@ -33,7 +33,7 @@
- "{{ awstats_data_dir }}" - "{{ awstats_data_dir }}"
- "{{ apache_log_dir }}" - "{{ apache_log_dir }}"
- name: Install the Apache config for AWStats - name: Install the Apache config for AWStats (debuntu)
template: src=apache.conf template: src=apache.conf
dest=/etc/{{ apache_config_dir }}/awstats.conf dest=/etc/{{ apache_config_dir }}/awstats.conf
owner=root owner=root
@ -41,7 +41,7 @@
mode=0644 mode=0644
when: awstats_enabled and is_debuntu when: awstats_enabled and is_debuntu
- name: Install the Apache config for AWStats - name: Install the Apache config for AWStats (OS's other than debuntu)
template: src=apache-awstats.conf template: src=apache-awstats.conf
dest=/etc/{{ apache_config_dir }}/awstats.conf dest=/etc/{{ apache_config_dir }}/awstats.conf
owner=root owner=root
@ -49,7 +49,7 @@
mode=0644 mode=0644
when: awstats_enabled and not is_debuntu when: awstats_enabled and not is_debuntu
- name: make sure logrotate does not make logs unreadable - name: make sure logrotate does not make logs unreadable (debuntu)
template: src=logrotate.d.apache2 template: src=logrotate.d.apache2
dest=/etc/logrotate.d/apache2 dest=/etc/logrotate.d/apache2
when: is_debuntu when: is_debuntu
@ -63,13 +63,13 @@
command: mv /etc/awstats/awstats.conf /etc/awstats/awstats.conf.dist command: mv /etc/awstats/awstats.conf /etc/awstats/awstats.conf.dist
when: awstats.stat.islnk is defined and not awstats.stat.islnk when: awstats.stat.islnk is defined and not awstats.stat.islnk
- name: Enable AWStats - name: Enable AWStats (debuntu)
file: src=/etc/apache2/sites-available/awstats.conf file: src=/etc/apache2/sites-available/awstats.conf
path=/etc/apache2/sites-enabled/awstats.conf path=/etc/apache2/sites-enabled/awstats.conf
state=link state=link
when: awstats_enabled and is_debuntu when: awstats_enabled and is_debuntu
- name: Disable AWStats - name: Disable AWStats (debuntu)
file: path=/etc/apache2/sites-enabled/awstats.conf file: path=/etc/apache2/sites-enabled/awstats.conf
state=absent state=absent
when: not awstats_enabled and is_debuntu when: not awstats_enabled and is_debuntu
@ -88,10 +88,10 @@
state=link state=link
when: awstats_enabled when: awstats_enabled
- name: On first enabling of AWStats, summarize httpd logs up to now - name: On first enabling of AWStats, summarize httpd logs up to now (OS's other than debuntu)
shell: /bin/perl /usr/share/awstats/wwwroot/cgi-bin/awstats.pl -config=schoolserver -update shell: /bin/perl /usr/share/awstats/wwwroot/cgi-bin/awstats.pl -config=schoolserver -update
when: awstats_enabled and not is_debuntu when: awstats_enabled and not is_debuntu
- name: On first enabling of AWStats, summarize httpd logs up to now - name: On first enabling of AWStats, summarize httpd logs up to now (debuntu)
shell: /usr/bin/perl /usr/lib/cgi-bin/awstats.pl -config=schoolserver -update shell: /usr/bin/perl /usr/lib/cgi-bin/awstats.pl -config=schoolserver -update
when: awstats_enabled and is_debuntu when: awstats_enabled and is_debuntu