-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.sh
73 lines (58 loc) · 1.47 KB
/
config.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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#!/bin/bash
#
set -euxo pipefail
# functions
#
test -f /.kconfig && . /.kconfig
test -f /.profile && . /.profile
# make sure the crb repo is enabled
#
dnf -y config-manager --set-enabled crb
# selinux, needed for kde and maybe others
#
setsebool -P selinuxuser_execmod 1
# set a hostname
#
echo "pumice" > /etc/hostname
# clear machine id
#
truncate -s 0 /etc/machine-id
# grub
#
echo "GRUB_DEFAULT=saved" >> /etc/default/grub
# services
#
#systemctl disable NetworkManager-wait-online
systemctl enable chronyd.service
systemctl enable systemd-oomd.service
systemctl enable systemd-resolved.service
# persistent logs
#
mkdir -p /var/log/journal
# clear root password
#
passwd -d root
passwd -l root
# we are live
#
echo 'livesys_session="gnome"' > /etc/sysconfig/livesys
sed -i "s/org.fedoraproject.AnacondaInstaller/anaconda/" /usr/share/applications/liveinst.desktop
# set default boot target (gui or cli)
#
systemctl set-default graphical.target
#systemctl set-default multi-user.target
# apply custom gnome stuff in /etc/dconf/db/local.d/99-pumice
#
dconf update
# setup flathub repo
#
flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
# el repo + dnf stuff
#
rpm --import https://www.elrepo.org/RPM-GPG-KEY-v2-elrepo.org
rpm -i --nodeps https://www.elrepo.org/elrepo-release-10.el10.elrepo.noarch.rpm
dnf -y --refresh update
dnf -y config-manager --set-enabled crb elrepo elrepo-extras elrepo-kernel epel
dnf clean all
dnf makecache
exit 0