1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67
|
wget -O reinstall.sh https://github.com/bin456789/reinstall/raw/main/reinstall.sh bash reinstall.sh debian --password [PASSWORD] --ssh-port [PORT] --hold 2
--hold 2 --frpc-toml /path/to/frpc.toml --web-port PORT --ssh-port PORT --password PASSWORD --ssh-key KEY --ssh-key "ssh-rsa ..." --ssh-key "ssh-ed25519 ..." --ssh-key "ecdsa-sha2-nistp256/384/521 ..." --ssh-key /path/to/public_key --ssh-key github:your_username --ssh-key http://path/to/public_key
./reinstall.sh alpine --hold=1 ./reinstall.sh netboot.xyz
...... menuentry "reinstall (debian 13)" --unrestricted { insmod lvm insmod all_video search --no-floppy --file --set=root /reinstall-vmlinuz linux /reinstall-vmlinuz lowmem/low=1 auto=true priority=critical url=https://raw.githubusercontent.com/bin456789/reinstall/main/debian.cfg mirror/http/hostname=deb.debian.org mirror/http/directory=/debian base-installer/kernel/image=linux-image-cloud-amd64 extra_confhome='https://raw.githubusercontent.com/bin456789/reinstall/main' extra_hold=2 extra_main_disk=45f2e6fa extra_elts=0 extra_deb_mirror=deb.debian.org/debian extra_ssh_port=22 initrd /reinstall-initrd }
/dev/vda1: UUID="67eedb9c-5877-4061-a42e-40d0aabf95a2" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="45f2e6fa-01"
/boot/grub/custom.cfg /reinstall.log /reinstall-initrd /reinstall-vmlinuz /reinstall-tmp/ ├── initrd/ ├── fdisk/ ├── control.tar.xz ├── data.tar.xz ├── debian-binary ├── tmp.udeb └── udeb_list
/etc/ssh/sshd_config.d/01-change-ssh-port.conf Port 22 /etc/ssh/sshd_config.d/01-permitrootlogin.conf PermitRootLogin yes
除此之外,它还可以添加一些密钥 root@localhost:~# tree -L 1 /etc/ssh/ /etc/ssh/ ...... ├── ssh_host_ecdsa_key ├── ssh_host_ecdsa_key.pub ├── ssh_host_ed25519_key ├── ssh_host_ed25519_key.pub ├── ssh_host_rsa_key └── ssh_host_rsa_key.pub
|