kickstarts/live/9/prod/rocky-live-xfce.ks

95 lines
3.2 KiB
Plaintext
Raw Normal View History

2021-06-04 23:37:27 +00:00
# rocky-live-kde.ks
# BROKEN
%include rocky-live-base-spin.ks
%include rocky-live-xfce-common.ks
part / --size 6144
%post
# xfce configuration
# create /etc/sysconfig/desktop (needed for installation)
cat > /etc/sysconfig/desktop <<EOF
PREFERRED=/usr/bin/startxfce4
2022-05-16 02:55:42 +00:00
DISPLAYMANAGER=/usr/sbin/lightdm
2021-06-04 23:37:27 +00:00
EOF
cat >> /etc/rc.d/init.d/livesys << EOF
mkdir -p /home/liveuser/.config/xfce4
2021-11-13 22:43:54 +00:00
# ugly stuff, this should give us a default background for now
2022-06-30 02:31:05 +00:00
#mkdir -p /usr/share/backgrounds/images
#ln -s /usr/share/backgrounds/f32/default/f32.png \
# /usr/share/backgrounds/images/default.png
2021-06-04 23:37:27 +00:00
cat > /home/liveuser/.config/xfce4/helpers.rc << FOE
MailReader=sylpheed-claws
FileManager=Thunar
WebBrowser=firefox
FOE
# disable screensaver locking (#674410)
cat >> /home/liveuser/.xscreensaver << FOE
mode: off
lock: False
dpmsEnabled: False
FOE
# deactivate xfconf-migration (#683161)
rm -f /etc/xdg/autostart/xfconf-migration-4.6.desktop || :
# deactivate xfce4-panel first-run dialog (#693569)
mkdir -p /home/liveuser/.config/xfce4/xfconf/xfce-perchannel-xml
cp /etc/xdg/xfce4/panel/default.xml /home/liveuser/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml
# set up lightdm autologin
2022-05-16 02:55:42 +00:00
sed -i 's/^#autologin-user=.*/autologin-user=liveuser/' /etc/lightdm/lightdm.conf
sed -i 's/^#autologin-user-timeout=.*/autologin-user-timeout=0/' /etc/lightdm/lightdm.conf
sed -i 's/^#show-language-selector=.*/show-language-selector=true/' /etc/lightdm/lightdm-gtk-greeter.conf
2021-06-04 23:37:27 +00:00
# set Xfce as default session, otherwise login will fail
2022-05-16 02:55:42 +00:00
sed -i 's/^#user-session=.*/user-session=xfce/' /etc/lightdm/lightdm.conf
2021-06-04 23:37:27 +00:00
# debrand
2022-07-11 16:09:49 +00:00
#sed -i "s/Red Hat Enterprise/Rocky/g" /usr/share/anaconda/gnome/fedora-welcome.desktop
#sed -i "s/RHEL/Rocky Linux/g" /usr/share/anaconda/gnome/fedora-welcome
#sed -i "s/Red Hat Enterprise/Rocky/g" /usr/share/anaconda/gnome/fedora-welcome
#sed -i "s/org.fedoraproject.AnacondaInstaller/fedora-logo-icon/g" /usr/share/anaconda/gnome/fedora-welcome
2021-06-28 01:49:46 +00:00
#sed -i "s/org.fedoraproject.AnacondaInstaller/fedora-logo-icon/g" /usr/share/applications/liveinst.desktop
2021-06-04 23:37:27 +00:00
# Show harddisk install on the desktop
sed -i -e 's/NoDisplay=true/NoDisplay=false/' /usr/share/applications/liveinst.desktop
mkdir /home/liveuser/Desktop
2022-05-15 15:47:38 +00:00
cp /usr/share/applications/liveinst.desktop /home/liveuser/Desktop/
2022-07-11 16:09:49 +00:00
if [ -f /usr/share/anaconda/gnome/fedora-welcome.desktop ]; then
2022-05-15 15:47:38 +00:00
mkdir -p ~liveuser/.config/autostart
2022-07-11 16:09:49 +00:00
cp /usr/share/anaconda/gnome/fedora-welcome.desktop /usr/share/applications/
cp /usr/share/anaconda/gnome/fedora-welcome.desktop ~liveuser/.config/autostart/
2022-05-15 15:47:38 +00:00
fi
2021-06-04 23:37:27 +00:00
# no updater applet in live environment
rm -f /etc/xdg/autostart/org.mageia.dnfdragora-updater.desktop
# and mark it as executable (new Xfce security feature)
chmod +x /home/liveuser/Desktop/liveinst.desktop
2022-05-15 15:47:38 +00:00
# move to anaconda - probably not required for XFCE.
mv /usr/share/applications/liveinst.desktop /usr/share/applications/anaconda.desktop
2021-06-04 23:37:27 +00:00
# this goes at the end after all other changes.
chown -R liveuser:liveuser /home/liveuser
restorecon -R /home/liveuser
EOF
2021-06-22 22:13:50 +00:00
# this doesn't come up automatically. not sure why.
2022-05-16 02:55:42 +00:00
systemctl enable --force lightdm.service
2022-06-30 02:31:05 +00:00
# CRB needs to be enabled for EPEL to function.
2022-05-26 16:48:43 +00:00
dnf config-manager --set-enabled crb
2021-06-22 22:13:50 +00:00
2021-06-04 23:37:27 +00:00
%end