Pārlūkot izejas kodu

Merge pull request #227 from ze42/geoip_debian

geoip: Debian support
tags/v0.37.4
Niels Abspoel pirms 6 gadiem
vecāks
revīzija
32f92e8acd
Revīzijas autora e-pasta adrese nav piesaistīta nevienam kontam
2 mainītis faili ar 9 papildinājumiem un 4 dzēšanām
  1. +4
    -0
      apache/map.jinja
  2. +5
    -4
      apache/mod_geoip.sls

+ 4
- 0
apache/map.jinja Parādīt failu

@@ -36,6 +36,8 @@
'mod_pagespeed_source': 'https://dl-ssl.google.com/dl/linux/direct/mod-pagespeed-stable_current_amd64.deb',
'mod_xsendfile': 'libapache2-mod-xsendfile',
'mod_fastcgi': 'libapache2-mod-fastcgi',
'mod_geoip': 'libapache2-mod-geoip',
'mod_geoip_database': 'geoip-database',

'vhostdir': '/etc/apache2/sites-available',
'confdir': '/etc/apache2/conf-available',
@@ -59,6 +61,8 @@
'mod_php5': 'php',
'mod_fcgid': 'mod_fcgid',
'mod_pagespeed_source': 'https://dl-ssl.google.com/dl/linux/direct/mod-pagespeed-stable_current_x86_64.rpm',
'mod_geoip': 'mod_geoip',
'mod_geoip_database': 'GeoIP',

'vhostdir': '/etc/httpd/vhosts.d',
'confdir': '/etc/httpd/conf.d',

+ 5
- 4
apache/mod_geoip.sls Parādīt failu

@@ -1,6 +1,6 @@
{% from "apache/map.jinja" import apache with context %}

{% if grains['os_family']=="RedHat" %}
{% if 'mod_geoip' in apache %}

include:
- apache
@@ -8,14 +8,15 @@ include:
mod-geoip:
pkg.installed:
- pkgs:
- GeoIP
- mod_geoip
- {{ apache.mod_geoip }}
- {{ apache.mod_geoip_database }}
- require:
- pkg: apache

- watch_in:
- module: apache-restart

{% if grains['os_family']=="RedHat" %}
geoip conf:
file.managed:
- name: {{ apache.confdir }}/geoip.conf
@@ -35,4 +36,4 @@ geoip database:
- salt://apache/files/{{ salt['grains.get']('os_family') }}/GeoIP.dat

{% endif %}
{% endif %}

Notiek ielāde…
Atcelt
Saglabāt