diff --git a/inventory/host_vars/nagios-internal.phx2.fedoraproject.org b/inventory/host_vars/nagios-internal.phx2.fedoraproject.org deleted file mode 100644 index ad126b0b51..0000000000 --- a/inventory/host_vars/nagios-internal.phx2.fedoraproject.org +++ /dev/null @@ -1,22 +0,0 @@ ---- -nm: 255.255.255.0 -gw: 10.5.126.254 -dns: 10.5.126.21 - -ks_url: http://10.5.126.23/repo/rhel/ks/kvm-rhel-7 -ks_repo: http://10.5.126.23/repo/rhel/RHEL7-x86_64/ -volgroup: /dev/vg_virthost01 -vmhost: virthost01.phx2.fedoraproject.org -datacenter: phx2 - -tcp_ports: ['22', '80', '443', '67', '68'] -udp_ports: ['67','68','69'] -custom_rules: [ - '-A INPUT -p tcp -m tcp -s 192.168.1.20 --dport 5666 -j ACCEPT', - '-A INPUT -p tcp -m tcp -s 10.5.126.13 --dport 873 -j ACCEPT', - '-A INPUT -p tcp -m tcp -s 192.168.1.59 --dport 873 -j ACCEPT', -] - -eth0_ip: 10.5.126.207 -csi_relationship: | - nagios-internal is currently a development host diff --git a/inventory/inventory b/inventory/inventory index 0e2534fc92..f55de138f9 100644 --- a/inventory/inventory +++ b/inventory/inventory @@ -428,10 +428,6 @@ noc02.fedoraproject.org [nagios-stg] noc01.stg.phx2.fedoraproject.org -# This name is not permanent but is meant for the dev env -[nagios-internal] -nagios-internal.phx2.fedoraproject.org - [notifs-backend] notifs-backend01.phx2.fedoraproject.org diff --git a/playbooks/hosts/nagios-internal.phx2.fedoraproject.org.yml b/playbooks/hosts/nagios-internal.phx2.fedoraproject.org.yml index 36f633e4d0..9f5b64586a 100644 --- a/playbooks/hosts/nagios-internal.phx2.fedoraproject.org.yml +++ b/playbooks/hosts/nagios-internal.phx2.fedoraproject.org.yml @@ -1,8 +1,8 @@ # This is a basic playbook -- include: "/srv/web/infra/ansible/playbooks/include/virt-create.yml myhosts=nagios-internal" +- include: "/srv/web/infra/ansible/playbooks/include/virt-create.yml myhosts=nagios-stg" - name: make the box be real - hosts: noc-internal.phx2.fedoraproject.org + hosts: noc01.stg.phx2.fedoraproject.org user: root gather_facts: True @@ -37,3 +37,20 @@ handlers: - include: "{{ handlers }}/restart_services.yml" +- name: deploy nagios service config + hosts: noc01.stg.phx2.fedoraproject.org + user: + gather_facts: True + + vars_files: + - /srv/web/infra/ansible/vars/global.yml + - "/srv/private/ansible/vars.yml" + - /srv/web/infra/ansible/vars/{{ ansible_distribution }}.yml + - "/srv/web/infra/ansible/vars/nagios.{{ inventory_hostname_short }}.yml" + + handlers: + - include: "{{ handlers }}/restart_services.yml" + + roles: + - nagios_server + - fedmsg/base