-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathconfigure.sh
executable file
·48 lines (36 loc) · 1.22 KB
/
configure.sh
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
#!/bin/bash
set -e
# Install Dotnet SDK
cd /home/devcade
wget https://packages.microsoft.com/config/debian/11/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
sudo apt-get update && \
sudo apt-get install -y dotnet-sdk-6.0
# Set up Onboard
cd devcade-onboard;
# Build onboard
cd onboard
dotnet publish -c release -r linux-x64 --self-contained
rm -rf /home/devcade/publish
mv bin/Release/net6.0/linux-x64/publish /home/devcade
cd ..
idiot_dir="/home/devcade/devcade-onboard/idiot"
# Env file
cp $idiot_dir/.env /home/devcade;
# Set up xinitrc
cp $idiot_dir/.xinitrc /home/devcade/.xinitrc
# Copy openbox config
mkdir -p /home/devcade/.config/openbox
cp $idiot_dir/rc.xml /home/devcade/.config/openbox
# Auto-login (scuffed)
sudo mkdir -p /etc/systemd/system/[email protected]/
sudo cp $idiot_dir/tty1_service_override.conf /etc/systemd/system/[email protected]/override.conf
# Add a thingy to the bashrc
until grep 'DEVCADE_AUTOLOGIN_INSTALLED' /home/devcade/.bashrc ; do
cat $idiot_dir/bashrc-check.sh >> /home/devcade/.bashrc
done
# Enable auto-login
sudo systemctl enable getty@tty1
# Also, disable root
sudo chsh root -s /usr/sbin/nologin