new.md aktualisiert

This commit is contained in:
2024-12-06 10:54:10 +01:00
parent 03220f4332
commit b77291fa8e

14
new.md
View File

@@ -1,3 +1,4 @@
````bash
apt-get update
apt-get full-upgrade -y
raspi-config
@@ -11,7 +12,9 @@ apt-get clean >>/var/log/install
rm -rf /var/lib/apt/lists/*
touch /root/.vnc/config.d/vncserver-x11
echo "Authentication=none" >> /root/.vnc/config.d/vncserver-x11
````
````bash
adduser --disabled-password --gecos "" loginuser
usermod -aG video loginuser
mkdir -p /etc/chromium/policies/managed /home/wis/.ssh /usr/bin/custom
@@ -28,7 +31,9 @@ loginuser ALL=(ALL) NOPASSWD: /usr/bin/hostnamectl set-hostname
loginuser ALL=(ALL) NOPASSWD: /usr/sbin/dhclient eth0
loginuser ALL=(ALL) NOPASSWD: /usr/sbin/reboot
EOF
````
````bash
mkdir -p /etc/systemd/system/getty@tty1.service.d/
declare -A files=(
["/root/rps-client/boot/ro-root.sh"]="/boot/ro-root.sh"
@@ -53,14 +58,15 @@ for src in "${!files[@]}"; do
echo "Copying $src to $dst..."
rsync $RSYNC_OPTS "$src" "$dst"
done
chown loginuser:loginuser -R /home/loginuser
chown wis:wis -R /home/wis
touch /var/log/watchdog.log /var/log/chromium-monitor.log /var/log/hostname.log
chown loginuser:loginuser /var/log/watchdog.log /var/log/chromium-monitor.log /var/log/hostname.log
chmod 777 /var/log/watchdog.log /var/log/chromium-monitor.log /var/log/hostname.log
chmod +x /usr/bin/custom/*
````
````bash
systemctl daemon-reload
systemctl enable hostname chromium-monitor getty@tty1
systemctl restart getty@tty1
@@ -72,4 +78,8 @@ EOF
sudo passwd -l root
bash /root/remove_unused_kernel.sh -u -e
reboot
````
````bash
reboot
````