Table of Contents

Current working URI setting

Name

  cwuri

Details

Type String
DHCP option number not applicable
ISC dhcpd syntax not applicable

Examples

Show script's own URI

  #!ipxe
  
  echo This script was loaded from ${cwuri}
  echo This script is in the directory ${cwduri}

Description

Represents the current working URI, i.e. the base URI relative to which any relative URIs will be resolved.

See also

Notes

When executing an iPXE script, the current working URI is set to the URI of the script itself. This allows the script to download subsequent files using relative paths, which will be interpreted as being relative to the script's own URI.

You can obtain the directory portion of the current working URI using the cwduri setting, and then use it to construct URI strings that can be passed to the booted operating system via its own command line.