Replaces many references to file: with ansible.builtin.file Signed-off-by: Ryan Lerch <rlerch@redhat.com>
69 lines
1.5 KiB
YAML
69 lines
1.5 KiB
YAML
---
|
|
|
|
#
|
|
# This is the role for geoip-city-wsgi.
|
|
#
|
|
# install necessary packages
|
|
- name: Install python-paste-deploy geolite2-city python2-iso3166 python2-geoip2
|
|
package:
|
|
name:
|
|
- python-paste-deploy
|
|
- geolite2-city
|
|
- python2-iso3166
|
|
- python2-geoip2
|
|
state: present
|
|
when: ansible_distribution_major_version|int < 8 and ansible_distribution == 'RedHat'
|
|
|
|
- name: Install python3-paste-deploy geolite2-city python3-iso3166 python3-geoip2
|
|
package:
|
|
name:
|
|
- python3-paste-deploy
|
|
- geolite2-city
|
|
- python3-iso3166
|
|
- python3-geoip2
|
|
state: present
|
|
when: ansible_distribution_major_version|int >= 8 and ansible_distribution == 'RedHat'
|
|
|
|
|
|
- name: Install geoip-city-wsgi.conf file
|
|
copy: >
|
|
src="geoip-city-wsgi.conf"
|
|
dest="/etc/httpd/conf.d/geoip-city-wsgi.conf"
|
|
owner=root
|
|
group=root
|
|
mode=0644
|
|
notify:
|
|
- reload httpd
|
|
tags:
|
|
- geoip_config
|
|
- config
|
|
- geoip-city-wsgi
|
|
- geoip-city-wsgi/app
|
|
|
|
- name: Setup /usr/share/geoip-city-wsgi directory
|
|
ansible.builtin.file: >
|
|
path=/usr/share/geoip-city-wsgi
|
|
owner=root
|
|
group=root
|
|
mode=0755
|
|
state=directory
|
|
tags:
|
|
- geoip_config
|
|
- config
|
|
- geoip-city-wsgi
|
|
- geoip-city-wsgi/app
|
|
|
|
- name: Install geoip-city.wsgi file
|
|
copy: >
|
|
src="geoip-city.wsgi"
|
|
dest="/usr/share/geoip-city-wsgi/geoip-city.wsgi"
|
|
owner=root
|
|
group=root
|
|
mode=0775
|
|
notify:
|
|
- reload httpd
|
|
tags:
|
|
- geoip_config
|
|
- config
|
|
- geoip-city-wsgi
|
|
- geoip-city-wsgi/app
|