# --- Paramètres globaux --- port=0 # Désactive la fonction serveur DNS (on ne veut que DHCP/TFTP) log-dhcp # --- Définition des réseaux et interfaces --- dhcp-range=set:net_eth0,10.0.0.50,10.0.0.150,255.255.255.0,2h dhcp-range=set:net_eth1,10.0.1.50,10.0.1.150,255.255.255.0,2h # --- Configuration TFTP --- enable-tftp tftp-root=/var/lib/tftpboot # --- Détection des clients (Tags) --- # Tag iPXE (Option 175) dhcp-match=set:ipxe,175 # Tag UEFI x86 (Option 93, architecture 00:07 ou 00:09) dhcp-match=set:efi-x86_64,option:client-arch,7 dhcp-match=set:efi-x86_64,option:client-arch,9 # Tag Raspberry Pi (Identifier la classe vendeur) dhcp-vendorclass=set:rpi,PXEClient:Arch:00000:UNDI:002001 # --- LOGIQUE DE DÉMARRAGE --- # 1. Si c'est un Raspberry Pi (sur eth1), on le pointe vers TFTP pour son firmware # (Note : le Pi cherchera automatiquement start4.elf à la racine du TFTP) pxe-service=tag:net_eth1,tag:rpi,"Raspberry Pi Boot",0 # 2. Si c'est un PC x86 (pas encore sous iPXE) # On envoie ipxe.efi si UEFI, sinon undionly.kpxe si BIOS classique dhcp-boot=tag:!ipxe,tag:!rpi,tag:efi-x86_64,ipxe.efi dhcp-boot=tag:!ipxe,tag:!rpi,tag:!efi-x86_64,undionly.kpxe # 3. Si le client est DÉJÀ sous iPXE, on le redirige vers le bon script HTTP selon l'interface dhcp-boot=tag:ipxe,tag:net_eth0,http://10.0.0.1/boot-eth0.ipxe dhcp-boot=tag:ipxe,tag:net_eth1,http://10.0.1.1/boot-eth1.ipxe