hypriot / flash

Command line script to flash SD card images of any kind
MIT License
1k stars 176 forks source link

Request: Use mac address of boot device for host name #105

Closed jmulvaney1 closed 6 years ago

jmulvaney1 commented 6 years ago

Any way that I can pass the mac address of the boot device to become the host name during first boot? MAC+fixed named.

StefanScherer commented 6 years ago

Maybe this could be done with some script commands in the /boot/user-data file for the cloud-init run on first boot. But it's not part of the flash tool itself.

StefanScherer commented 6 years ago

Maybe you find some inspiration in https://cloudinit.readthedocs.io/en/latest/