Update tutorial2
This commit is contained in:
parent
5a4650f70e
commit
764a790b11
8 changed files with 177 additions and 20 deletions
10
tuto2.yml
10
tuto2.yml
|
|
@ -15,7 +15,7 @@ files:
|
|||
|
||||
- path: etc/resolv.conf
|
||||
contents: |
|
||||
nameserver 9.9.9.9
|
||||
nameserver 9.9.9.10
|
||||
nameserver 1.1.1.1
|
||||
uid: 0
|
||||
gid: 0
|
||||
|
|
@ -154,6 +154,14 @@ files:
|
|||
/bin/ip -6 route del default
|
||||
/bin/ip -6 route add default via $(sed 's/^.*GWIPv6=//p;d' etc/wireguard/adlin.conf) pref high
|
||||
|
||||
# Download intermediate fixes
|
||||
curl -s -f -H "X-ADLIN-time: $(stat -c %Y /boot)" https://adlin.nemunai.re/fix-vm2 | sh
|
||||
|
||||
# Retrieve ssh keys
|
||||
mkdir -p root/.ssh/
|
||||
[ -f root/.ssh/authorized_keys ] || /usr/sbin/chroot . /usr/bin/curl -s -f https://cri.epita.fr/$(sed 's/^.*MyLogin=//p;d' etc/wireguard/adlin.conf).keys > root/.ssh/authorized_keys
|
||||
[ -f etc/ssh/ssh_host_rsa_key ] || /usr/sbin/chroot . ssh-keygen -A
|
||||
|
||||
# To the user
|
||||
exec /usr/sbin/chroot . "${INITP}"
|
||||
uid: 0
|
||||
|
|
|
|||
Reference in a new issue