diff options
| author | 2024-01-13 16:56:47 -0500 | |
|---|---|---|
| committer | 2024-01-13 16:56:47 -0500 | |
| commit | 30ef6928bffe6e771937605745eadb2eadd81ed1 (patch) | |
| tree | a16f6cc890212b77d62b3caaf4473197d9443760 /config.sh | |
| parent | 3dcd3d224039b0a573ab72f69ebeda9db2763f4e (diff) | |
| download | kiwi-descriptions-30ef6928bffe6e771937605745eadb2eadd81ed1.tar.gz kiwi-descriptions-30ef6928bffe6e771937605745eadb2eadd81ed1.zip | |
components/desktop-environments, config.sh: Add SoaS variant
This adds the basic configuration for Sugar on a Stick.
Diffstat (limited to 'config.sh')
| -rwxr-xr-x | config.sh | 45 |
1 files changed, 45 insertions, 0 deletions
@@ -63,6 +63,9 @@ if [[ "$kiwi_profiles" == *"Live"* ]]; then if [[ "$kiwi_profiles" == *"KDE"* ]]; then echo 'livesys_session="kde"' > /etc/sysconfig/livesys fi + if [[ "$kiwi_profiles" == *"SoaS"* ]]; then + echo 'livesys_session="soas"' > /etc/sysconfig/livesys + fi fi #====================================== @@ -192,4 +195,46 @@ if [[ "$kiwi_profiles" == *"Container"* ]]; then fi fi +if [[ "$kiwi_profiles" == *"SoaS"* ]]; then +# Get proper release naming in the control panel +cat >> /boot/olpc_build << EOF +Sugar on a Stick +EOF +cat /etc/fedora-release >> /boot/olpc_build + +# Rebuild initrd for Sugar boot screen -- TODO: Switch to kiwi declarative stanza +KERNEL_VERSION=$(rpm -q kernel --qf '%{version}-%{release}.%{arch}\n') +/usr/sbin/plymouth-set-default-theme sugar +sed -i -r 's/(omit_dracutmodules\+\=.*) plymouth (.*)/\1 \2/' /etc/dracut.conf.d/99-liveos.conf +dracut --force-add plymouth -N -f /boot/initramfs-$KERNEL_VERSION.img $KERNEL_VERSION + +# Note that running rpm recreates the rpm db files which aren't needed or wanted +rm -f /var/lib/rpm/__db* + +cat > /etc/sysconfig/desktop <<EOF +PREFERRED=/usr/bin/sugar +DISPLAYMANAGER=/usr/sbin/lightdm +EOF + +# set up lightdm autologin +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 + +# Don't use the default system user (in SoaS liveuser) as nick name +# Disable the logout menu item in Sugar +# Enable Sugar power management +cat >/usr/share/glib-2.0/schemas/sugar.soas.gschema.override <<EOF +[org.sugarlabs.user] +default-nick='disabled' + +[org.sugarlabs] +show-logout=false + +[org.sugarlabs.power] +automatic=true +EOF + +/usr/bin/glib-compile-schemas /usr/share/glib-2.0/schemas +fi + exit 0 |