Created
April 29, 2025 11:26
-
-
Save sbraz/bcd9307f2b14ad84a67d4665473560cd to your computer and use it in GitHub Desktop.
iPXE script to boot into a live Alpine Linux rescue on OVHcloud bare metal servers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!ipxe | |
| echo Booting Alpine Linux rescue | |
| # Used below for SSH keys | |
| set space:hex 20 | |
| set space ${space:string} | |
| set arch x86_64 | |
| #set version edge | |
| set version latest-stable | |
| #set mirror https://dl-cdn.alpinelinux.org/alpine | |
| set mirror https://alpinelinux.mirrors.ovh.net | |
| # To see the whole boot process, adjust the console parameters based on what | |
| # you see in the official rescue's /proc/cmdline | |
| #set console console=tty0${space}console=ttyS0,115200n8 | |
| # Enable the community repository for ripgrep | |
| set repo-url ${mirror}/${version}/main,${mirror}/${version}/community | |
| set packages bash,curl,file,lsblk,mount,parted,ripgrep,vim,wget | |
| set ssh_key ssh-ed25519${space}AAAAxxxxxxxxxx | |
| set base-url ${mirror}/${version}/releases/${arch}/netboot | |
| imgfree | |
| kernel ${base-url}/vmlinuz-lts initrd=initrd.magic ${console} ip=dhcp alpine_repo=${repo-url} modules=loop,squashfs modloop=${base-url}/modloop-lts pkgs=${packages} ssh_key="${ssh_key}" | |
| initrd ${base-url}/initramfs-lts | |
| boot |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment