#
# Configure sysklogd and tcp-wrapper for it.  Most of this
# can be removed when Debian bug #205239 is fixed.
#
links:

  # On server and ltsp-server
  debian.server|debian.ltspserver::

    # Enable UDP to make sure to syslog messages are accepted via UDP
    /etc/rsyslog.d/debian-edu-collector.conf ->! /usr/share/debian-edu-config/rsyslog-collector
                nofile=force

editfiles:

  # On server.  FIXME tcp-wrapper do not seem to be used by rsyslogd
  debian.server::

    # edit /etc/hosts.{allow,deny} to allow syslog packages from 10.0.0.0/8
    { /etc/hosts.allow
      AppendIfNoSuchLine "syslog: 10."
    }

  # On ltsp-server
  debian.ltspserver::

    # edit /etc/hosts.{allow,deny} to allow syslog packages from 192.168.0.0/24
    { /etc/hosts.allow
      AppendIfNoSuchLine "syslog: 192.168.0."
    }

  # On every host except the server and a standalone machine, send
  # syslog messages to the central collector.
  debian.!server.!standalone::
    { /etc/rsyslog.d/debian-edu-client.conf
      AutoCreate
      AppendIfNoSuchLine "*.* @${syslogserver}"
    }

files:
  debian.secondpass.!server.!standalone::
	/etc/rsyslog.d/debian-edu-client.conf mode=644 act=fixall
