apache-formula/apache/mod_geoip.sls
Imran Iqbal e55ef9b3ee
fix(mod_geoip.sls): fix salt-lint errors
```bash
Examining apache/mod_geoip.sls of type state
[201] Trailing whitespace
apache/mod_geoip.sls:30
    - source:
```
2019-10-17 08:32:30 +01:00

44 lines
900 B
Plaintext

{% from "apache/map.jinja" import apache with context %}
{% if 'mod_geoip' in apache %}
include:
- apache
mod-geoip:
pkg.installed:
- pkgs:
- {{ apache.mod_geoip }}
- {{ apache.mod_geoip_database }}
- require:
- pkg: apache
- watch_in:
- module: apache-restart
- require_in:
- module: apache-restart
- module: apache-reload
- service: apache
{% if grains['os_family']=="RedHat" %}
geoip conf:
file.managed:
- name: {{ apache.confdir }}/geoip.conf
- user: root
- group: root
- mode: 644
- source:
- salt://apache/files/{{ salt['grains.get']('os_family') }}/geoip.conf
geoip database:
file.managed:
- name: /usr/share/GeoIP/GeoIP.dat
- user: root
- group: root
- mode: 644
- source:
- salt://apache/files/{{ salt['grains.get']('os_family') }}/GeoIP.dat
{% endif %}
{% endif %}