Skip to content

Instantly share code, notes, and snippets.

@EntropyWorks
Created June 13, 2012 07:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save EntropyWorks/2922493 to your computer and use it in GitHub Desktop.
Save EntropyWorks/2922493 to your computer and use it in GitHub Desktop.
Very Basic iPXE php script
<?php
echo "#!ipxe\n";
$install = true;
$server_ip = "192.168.1.1";
$proxy = "http_proxy=http://192.168.1.1:8080";
$kickstart = "ubuntu-12.04-LTS.ks"
if ($install) {
//default to ubuntu live system
?>
set base-url http://<?php echo $server_ip; ?>/iso/loop/install/netboot/ubuntu-installer/amd64
kernel ${base-url}/linux
initrd ${base-url}/initrd.gz
imgargs linux auto=true ks=http://<?php echo $server_ip; ?>/ks/<?php echo $kickstart; ?> <?php echo $proxy; ?>
<?php
}
?>
boot
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment