# Define SERVERS with a list of one or more DHCP servers where
# DHCP packets are to be relayed to and from.  This is mandatory.
#SERVERS="10.11.12.13 10.9.8.7"

SERVERS="%%adresse_ip_dhcp_dhcrelay"
%if 'all' not in %%dhcrelay_interfaces
 %set %%dhc_server_int = %%getVar('nom_zone_eth' + %%dhcrelay_server_interface)
OPTIONS="%slurp
 %set %%serv_int_ok = []
 %for %%dhcrelay_int in %%dhcrelay_interfaces
  %if not %%is_empty(%%dhcrelay_int.dhcrelay_vlan)
   %set %%dhc_int = %%getVar('nom_zone_eth' + %%dhcrelay_int)+'.'+%%str(%%dhcrelay_int.dhcrelay_vlan)
  %else
   %set %%dhc_int = %%getVar('nom_zone_eth' + %%dhcrelay_int)
  %end if
  %if %%dhc_int == %%dhc_server_int
   %silent %%serv_int_ok.append('OK')
  %end if
-i %%dhc_int %slurp
 %end for
 %if 'OK' not in %%serv_int_ok
-i %%dhc_server_int%slurp
 %end if
"
%end if

# Define OPTIONS with any other options to pass to the dhcrelay server.
# See dhcrelay(8) for available options and syntax.
#OPTIONS="-q -i eth0 -i eth1"

