mirror of
https://github.com/ipxe/ipxe
synced 2025-12-21 04:20:17 +03:00
For some unspecified "security" reason, the Google Compute Engine
metadata server will refuse any requests that do not include the
non-standard HTTP header "Metadata-Flavor: Google".
Attempt to autodetect such requests (by comparing the hostname against
"metadata.google.internal"), and add the "Metadata-Flavor: Google"
header if applicable.
Enable this feature in the CONFIG=cloud build, and include a sample
embedded script allowing iPXE to boot from a script configured as
metadata via e.g.
# Create shared boot image
make bin/ipxe.usb CONFIG=cloud EMBED=config/cloud/gce.ipxe
# Configure per-instance boot script
gcloud compute instances add-metadata <instance> \
--metadata-from-file ipxeboot=boot.ipxe
Signed-off-by: Michael Brown <mcb30@ipxe.org>
5 lines
134 B
C
5 lines
134 B
C
/* Allow retrieval of metadata (such as an iPXE boot script) from
|
|
* Google Compute Engine metadata server.
|
|
*/
|
|
#define HTTP_HACK_GCE
|