9ff0a30d9ed011f5b1d8f1f975e1da406073c578
[distro-setup] / bitfolk-rescue-init
1 #!/bin/bash
2
3 # meant to be copy/pasted
4
5 ssh bk@bk.console.bitfolk.com
6 # or
7 ssh iankelling@iankelling.console.bitfolk.com
8
9 destroy
10 rescue
11 sudo -i
12 mkdir -p /root/.ssh
13 chmod 700 /root/.ssh
14 cat >/root/.ssh/authorized_keys <<'EOF'
15 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDX42yru/h6r6UDRy/VwVZjcYEmNLG5/SUjv7xwu43OaW0wL+uHYg2rkfn4Ygh5o1I5pgBh2SWg8TeWuVGhgL1SCuBzzeai/+58Sny065Qak+D2WjVOuRonRelh+CBA5EpNZPuiWQkoWdf9NACTBCbS2Zu7r8OOgRqu/ruaDNePlG5+U0Wlpy3oBnpbzQiuSA3AKMW30fsCJtOBjz5qQaiPbYEKJy3AOvtbq10wliKx9TpsTzrq8dKWs7PLhZnzqVCsaq6D95IzjqXcSpx4Cga5bn+YEuAnJQ53PGA5eO+hpz6HDmawTbJlaV/Dufb9bJ/ZZy1DXzs07yWRtTEY54/X ian@iankelling.org
16 EOF
17 apt update
18 apt -y install openssh-server
19
20
21 ##### in another terminal ######
22
23 host=je
24 scp /b/ds/bitfolk* root@$host.b8.nz:
25 ssh root@$host ./bitfolk-rescue-install $host
26
27 ### back to the 1st terminal
28
29 poweroff
30 boot
31
32 # press ctrl ]
33 exit
34
35 jepush
36 # todo: lets copy the host keys around so we dont have to do this.
37 khfix je
38 sl root@je /a/bin/ds/distro-begin
39
40 # todo, fix it so i can ssh to
41 sl je /a/bin/ds/distro-begin
42 sl je /a/bin/ds/distro-end