diff --git a/playbooks/mirror.yml b/playbooks/mirror.yml index 18dc167..4ae2bab 100644 --- a/playbooks/mirror.yml +++ b/playbooks/mirror.yml @@ -28,10 +28,10 @@ - mirror/base - mirror/thinlinc - role: mirror/reportmirror - hostname: mirrors.foo.sh - mirrors: [epel, fedora] - sitename: foo.sh - password: "{{ report_mirror_pass }}" + mirror_hostname: mirrors.foo.sh + mirror_mirrors: [epel, fedora] + mirror_sitename: foo.sh + mirror_password: "{{ report_mirror_pass }}" - role: mirror/sync mirror_label: fedora-epel mirror_source: diff --git a/roles/mirror/reportmirror/defaults/main.yml b/roles/mirror/reportmirror/defaults/main.yml index c2ae745..79a2016 100644 --- a/roles/mirror/reportmirror/defaults/main.yml +++ b/roles/mirror/reportmirror/defaults/main.yml @@ -1,4 +1,4 @@ --- -hostname: "{{ inventory_hostname }}" -mirrors: [] +mirror_hostname: "{{ inventory_hostname }}" +mirror_mirrors: [] diff --git a/roles/mirror/reportmirror/templates/report_mirror.conf.j2 b/roles/mirror/reportmirror/templates/report_mirror.conf.j2 index ae793f3..59d4dbb 100644 --- a/roles/mirror/reportmirror/templates/report_mirror.conf.j2 +++ b/roles/mirror/reportmirror/templates/report_mirror.conf.j2 @@ -11,8 +11,8 @@ enabled=1 # Name and Password fields need to match the Site name and password # fields you entered for your Site in the MirrorManager database at # https://admin.fedoraproject.org/mirrormanager -name={{ sitename }} -password={{ password }} +name={{ mirror_sitename }} +password={{ mirror_password }} [host] # if enabled=0, no data about this host is sent to the database @@ -20,7 +20,7 @@ enabled=1 # Name field need to match the Host name field you entered for your # Host in the MirrorManager database at # https://admin.fedoraproject.org/mirrormanager -name={{ hostname }} +name={{ mirror_hostname }} # if user_active=0, no data about this category is given to the public # This can be used to toggle between serving and not serving data, # such enabled during the nighttime (when you have more idle bandwidth @@ -52,7 +52,7 @@ rsyncd=/var/log/rsyncd.log # path= is the path on your local disk to the top-level directory for this Category [Fedora Linux] -{% if "fedora" in mirrors %} +{% if "fedora" in mirror_mirrors %} enabled=1 {% else %} enabled=0 @@ -60,7 +60,7 @@ enabled=0 path=/srv/mrirors/fedora [Fedora EPEL] -{% if "epel" in mirrors %} +{% if "epel" in mirror_mirrors %} enabled=1 {% else %} enabled=0