<?xml version="1.0" encoding="utf-8"?>

<creole>
    <containers>
        <container name='fichier'>
            <interface linkto="eth1" ip="adresse_ip_fichier_link" mask="adresse_mask_fichier_link" bcast="adresse_bcast_fichier_link" redefine='True'>eth1</interface>
        </container>
    </containers>

    <variables>
        <family name='general'>
            <variable name='nombre_interfaces' redefine='True' mode='normal'/>
            <variable name='eole_module' redefine='True'>
                <value>amonecole</value>
            </variable>
            <variable name='fichier_link_interface' redefine='True' hidden='True'>
                <value>eth1</value>
            </variable>
        </family>
        <family name='services'>
            <variable name='activer_dhcprelay' redefine='True' hidden='True'/>
            <variable name='activer_clam' redefine='True'>
                <value>oui</value>
            </variable>
        </family>
        <family name='firewall'>
            <variable name='type_amon' redefine='True'>
                <value>2zones-amonecole</value>
            </variable>
            <variable name='install_scribe_dmz' redefine='True' hidden='True'/>
        </family>
        <family name='Interface-0'>
            <variable name='eth0_method' redefine='True' hidden='False'/>
        </family>
        <family name='Interface-1'>
            <!--change les variables de famille-->
            <variable name='adresse_ip_fichier_link' remove_check="True" redefine="True"/>
            <variable name='adresse_mask_fichier_link' redefine="True" />
            <variable name='adresse_bcast_fichier_link' redefine="True" />
        </family>
        <family name='tftp'>
            <variable name='adresse_ip_tftp' redefine="True" />
        </family>
        <family name='Reverse proxy' hidden='True'>
            <!-- pour ne pas ouvrir l'EAD sur le port 4203-->
            <variable name='revprox_ead_port' redefine='True' hidden='True'>
                <value></value>
            </variable>
        </family>
        <family name='esu'>
            <!-- proxy ESU activé par défaut sur AmonEcole #1964 -->
            <variable name='esu_proxy' redefine='True'>
                <value>oui</value>
            </variable>
            <variable name='esu_proxy_bypass' redefine='True'/>
            <variable name='tmp_esu_proxy_bypass' type='string' description="Valeur temporaire pour le calcul de esu_proxy_bypass" hidden='True'/>
            <variable name='tmp_esu_proxy_bypass2' type='string' description="Valeur temporaire pour le calcul de esu_proxy_bypass2" hidden='True'/>
        </family>
        <family name='ead-web' mode='expert'>
            <!-- mis à oui dans 30_scribe.xml -->
            <variable name='activer_ead_reverseproxy' redefine='True'>
                <value>non</value>
            </variable>
        </family>
        <family name='authentification'>
            <!-- authentification web activée par défaut sur AmonEcole #1965 -->
            <variable name='activer_squid_auth' redefine='True' mode='normal'>
                <value>oui</value>
            </variable>
        </family>
        <family name='applications web'>
            <variable name='activer_web_behind_revproxy' redefine='True' hidden='True'>
                <value>oui</value>
            </variable>
        </family>
        <family name='proxy authentifié'>
            <variable name='type_squid_auth' redefine='True' mode='normal'/>
            <variable name='ip_serveur_ldap1' redefine='True'/>
        </family>
        <family name='dhcp'>
            <variable name='adresse_network_dhcp' redefine='True' mode='basic'/>
            <variable name='adresse_netmask_dhcp' redefine='True' mode='basic'/>
        </family>
    </variables>
    <constraints>
        <!-- Adresse IP du serveur LDAP sur eth1 -->
        <!--<auto name='calc_val' target='adresse_ip_ldap_exterieur'>
            <param type='eole' name='valeur'>adresse_ip_eth1</param>
        </auto>-->
        <check name="valid_in_network" target="adresse_ip_fichier_link" level="warning">
            <param type='eole'>adresse_network_eth1</param>
            <param type='eole'>adresse_netmask_eth1</param>
        </check>
        <check name="valid_differ" target="adresse_ip_fichier_link">
            <param type='eole'>adresse_ip_eth1</param>
        </check>
        <check name="valid_differ" target="adresse_ip_fichier_link">
            <param type='eole'>adresse_ip_eth1_proxy_link</param>
        </check>
        <check name="valid_differ" target="nom_machine" level="warning">
            <param type='eole'>smb_netbios_name</param>
        </check>
        <check name="valid_differ" target="web_url" level="warning">
            <param type='eole'>smb_netbios_name</param>
        </check>
        <fill name='calc_val' target='adresse_ip_tftp'>
            <param type='eole' name='valeur'>adresse_ip_fichier_link</param>
        </fill>
        <!-- AmonEcole >= 2 cartes réseau -->
        <check name="valid_enum" target="nombre_interfaces">
            <param>['2','3','4','5']</param>
        </check>
        <check name="valid_enum" target="eth0_method">
            <param>['statique','dhcp','pppoe']</param>
        </check>
        <!-- Configuration automatique du proxy sur eth1 -->
        <fill name='calc_val' target='adresse_network_dhcp'>
            <param type='eole' name='valeur'>adresse_network_eth1</param>
        </fill>
        <fill name='calc_val' target='adresse_netmask_dhcp'>
            <param type='eole' name='valeur'>adresse_netmask_eth1</param>
        </fill>
        <fill name='calc_val' target='adresse_ip_gw_dhcp'>
            <param type='eole' name='valeur'>adresse_ip_eth1</param>
        </fill>
        <fill name='calc_val' target='adresse_ip_dns_dhcp'>
            <param type='eole' name='valeur'>adresse_ip_eth1_proxy_link</param>
        </fill>
        <!-- déjà calculé sur 2.4 :)
        <fill name='calc_val' target='adresse_bcast_fichier_link'>
            <param type='eole' name='valeur'>adresse_broadcast_eth1</param>
        </fill>
        <fill name='calc_val' target='adresse_mask_fichier_link'>
            <param type='eole' name='valeur'>adresse_netmask_eth1</param>
        </fill>-->
        <!-- Configuration automatique de l'authentification du proxy -->
        <fill name='calc_val' target='nom_serveur_smb'>
            <param type='eole' name='valeur'>smb_netbios_name</param>
        </fill>
        <fill name='calc_val' target='nom_domaine_smb'>
            <param type='eole' name='valeur'>smb_workgroup</param>
        </fill>
        <fill name='calc_container' target='ip_serveur_smb'>
            <param type='eole'>mode_conteneur_actif</param>
            <param type='container'>fichier</param>
            <param type='eole' optional='True'>mode_zephir</param>
        </fill>
        <fill name='calc_container' target='ip_serveur_ldap1'>
            <param type='eole'>mode_conteneur_actif</param>
            <param type='container'>annuaire</param>
            <param type='eole' optional='True'>mode_zephir</param>
        </fill>
        <fill name='calc_val' target='esu_proxy_server'>
            <param type='eole' name='valeur'>adresse_ip_eth1_proxy_link</param>
        </fill>
        <fill name='calc_classe' target='tmp_esu_proxy_bypass'>
            <param type='eole'>adresse_netmask_eth1</param>
        </fill>
        <fill name='concat' target='tmp_esu_proxy_bypass2'>
            <param type='eole' name='valeur1'>adresse_network_eth1</param>
            <param name='valeur2'>/</param>
            <param type='eole' name='valeur3'>tmp_esu_proxy_bypass</param>
        </fill>
        <fill name='calc_multi_val' target='esu_proxy_bypass'>
            <param>127.0.0.1</param>
            <param type='eole'>tmp_esu_proxy_bypass2</param>
        </fill>
        <fill name='calc_val' target='activer_revprox'>
            <param type='eole' name='valeur'>activer_apache</param>
        </fill>
        <auto name='calc_val' target='web_behind_revproxy_ip'>
            <param type='eole'>adresse_ip_br0</param>
        </auto>
        <fill name='calc_multi_condition' target='revprox_auto_config_local_web'>
            <param>oui</param>
            <param type='eole' name='condition_1'>activer_apache</param>
            <param type='eole' name='condition_2'>activer_revprox</param>
            <param name='match'>oui</param>
            <param name='mismatch'>non</param>
        </fill>
    </constraints>
    <help/>
</creole>
<!-- vim: ts=4 sw=4 expandtab
-->
