diff options
33 files changed, 1425 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..ddc35b3 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +*~ +.*.swp +*.tmp diff --git a/automatic-build b/automatic-build new file mode 100755 index 0000000..3ce68a3 --- /dev/null +++ b/automatic-build @@ -0,0 +1,481 @@ +#!/bin/bash + +# !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! +# !! !! +# !! Designed to be run on non-persistent !! +# !! worker nodes only. Will mess with !! +# !! the running OS! !! +# !! Must be run as root. !! +# !! !! +# !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +# Config +# TODO: Make configurable via external include, check required vars are set + +# Supports deb/apt based distros for now +#distro="ubuntu" +#release="focal" +#mirror="ftp.halifax.rwth-aachen.de" +#pkg_sources="main restricted universe" +distro="debian" +release="bookworm" +mirror="ftp.halifax.rwth-aachen.de" +pkg_sources="main contrib" + +# if you don't put a kernel.config in $ROOT_DIR, this will be used +# fallback would be the running kernel's config +kernel_base_config="https://github.com/archlinux/svntogit-packages/raw/packages/linux/trunk/config" + +# https://git.openslx.org/bwlp/ansible-bwlp.git/tree/desktop-common/tasks/main.yml + +MLTK_CONFIG=' +export http_proxy="http://132.230.4.234:8123/" +sourceforge_mirror="netcologne" + +CONFIG_NFS_CACHE="10.4.180.32:/escience-bwlp01" + +NVIDIA_VERSIONS="550.127.05 390.157" +CONFIG_KERNEL_VERSION="6.6.60" +CONFIG_VMWARE_VERSION="17.6.1" +CONFIG_VBOX_VERSION="7.1.4" +CONFIG_QEMU_VERSION="v9.1.1" +CONFIG_VIRTMANAGER_VERSION="4.1.0" +CONFIG_LIBTPMS_VERSION="v0.9.6" +CONFIG_SWTPM_VERSION="v0.9.0" +' + +################## +# # +# End config # +# # +################## + +disabled_services= +pkgs_dummy= # "libwayland-dev libwayland-client0" +pkgs_full= +pkgs_lean= +tmp_dir= + +perror () { + echo "[ERROR] $*" >&2 + kill "$ppid" + exit 1 +} + +load_config() { + local i + local dir="configs/$1" + [ -d "$dir" ] || perror "Could not find directory '$dir'" + for i in disabled_services pkgs_dummy pkgs_full pkgs_lean; do + [ -s "$dir/$i" ] || continue + declare -g "$i=${!i} $( cat "$dir/$i" )" + done +} + +# Parse options, load configs +while [ $# -gt 0 ]; do + case "$1" in + --tmpfs) + tmp_dir=tmpfs + ;; + --tmpdir) + tmp_dir="$2" + shift + ;; + --*) + perror "Unknown option '$1'" + ;; + *) + load_config "$1" + ;; + esac + shift +done + +[ -z "$tmp_dir" ] && perror "No temp dir set. use --tmpdir <dir> or --tmpfs" + +ppid="$$" + +export DEBIAN_FRONTEND="noninteractive" + +apt update +# Breaks on current MaxiLinux because of missing kernel +apt remove -y initramfs-tools +# Essential tools +apt install -y systemd-container debootstrap equivs gdisk \ + || perror "Cannot install nspawn or debootstrap" + +run () { + systemd-nspawn -E DEBIAN_FRONTEND="noninteractive" -D "${root}/" "$@" +} + +fix_resolv () { + # resolv.conf used during build process is just copied from host + unlink "${root}/etc/resolv.conf" + cp -L "/etc/resolv.conf" "${root}/etc/resolv.conf" || perror "No resolv.conf" + [ -L "${root}/etc/resolv.conf" ] && perror "resolv.conf is still a link" +} + +# https://git.openslx.org/bwlp/ansible-bwlp.git/tree/dummy-package/scripts/dummy-package.sh +# <tmpdir> +dummy_package () { + [ "$#" -eq 2 ] || return 1 + [ -d "$1" ] || return 2 + rm -f -- "$2" || return 3 + + cd "$1" || return 4 + + equivs-control "$2" || return 5 + + sed -r -i \ + -e "s/^(#\s)?(Maintainer).*/\\2: support@bwlehrpool.de/" \ + -e "s/^(#\s)?(Package).*/\\2: ${2}/" \ + -e "s/^(#\s)?(Version).*/\\2: 99.9.9/" \ + -e "s/^(#\s)?(Description).*/\\2: Dummy package to provide $2/" \ + -e "/^Description.*/q" \ + "$2" + + cat >> "$2" <<-EOF + Long description + . + with + some + more + lines + EOF + + equivs-build "$2" +} + +declare -rg ARG0="$0" +declare -rg SELF="$(readlink -f "$ARG0")" +declare -rg ROOT_DIR="$(dirname "${SELF}")" + +modprobe -a overlay nbd nfs nfsv4 || perror "Could not load overlay and nbd and nfs" + +if [ "$tmp_dir" = "tmpfs" ]; then + base="/tmp/mltk-work" + mkdir -p "${base}" + if mountpoint "${base}"; then + umount "${base}" || perror "Could not unmount old workdir" + fi + # Generous 100G tmpfs, should be enough... + mount -t tmpfs -o size=100G mltk-build "${base}" || perror "Tmpfs fail" +elif [ -d "${tmp_dir}" ]; then + perror "${tmp_dir} must not exist!" +else + base="${tmp_dir}" + mkdir -p "${base}" +fi + +cd "${base}" || perror "Cannot cd to '${base}'" +root="${base}/fstree" +mkdir -p "${root}" "${base}/mnt" || perror "mkdir root" + +# TODO: Hard-coded apt-cacher-ng +debootstrap --variant=minbase --arch=amd64 \ + --include="build-essential,dbus,binutils,lsb-release,wget,rsync,gpg" \ + "${release}" "${root}" \ + "http://10.4.9.64:3142/${mirror}/${distro}/" || perror "debootstrap failed" + +fix_resolv + +# Static +rsync -avHAX --chown=0:0 "${ROOT_DIR}/data/" "${root}/" || perror "Could not sync data dir" + +# Create and install fake packages +mkdir -p /tmp/dummypkg || perror "Could not create tmp dir for dummy packages" +for pkg in $pkgs_dummy; do + dummy_package /tmp/dummypkg "$pkg" || perror "Could not create dummy package $pkg" +done +mkdir -p "${root}/dummypkg" +mv -f /tmp/dummypkg/*.deb "${root}/dummypkg/" || perror "Could not move dummy packages to ${root}" +cd "${base}" || perror "Doof dir" + +run /bin/sh -c 'dpkg -i /dummypkg/*.deb && rm -rf -- /dummypkg' || perror "Could not install dummy packages" +run apt-mark hold $pkgs_dummy || perror "Could not apt-mark hold" + +# TODO: WTF? +run apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 112695A0E562B32A +run apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 54404762BBB6E853 + +mkdir -p "${root}/etc/apt/apt.conf.d" +# Use our apt cache while building, but remove afterwards (TODO: Configurable as above) +cat > "${root}/etc/apt/apt.conf.d/01proxy" <<END +Acquire::http { Proxy "http://10.4.9.64:3142"; }; +Acquire::https { Proxy "https://"; }; +END + +if [ "$distro" = "ubuntu" ]; then + cat > "${root}/etc/apt/sources.list" <<-END + deb http://${mirror}/${distro} ${release} ${pkg_sources} + deb http://${mirror}/${distro} ${release}-updates ${pkg_sources} + deb http://${mirror}/${distro} ${release}-security ${pkg_sources} + END +else + cat > "${root}/etc/apt/sources.list" <<-END + deb http://${mirror}/${distro} ${release} ${pkg_sources} + deb http://${mirror}/${distro} ${release}-updates ${pkg_sources} + deb http://security.${distro}.org/${distro}-security ${release}-security ${pkg_sources} + END +fi + +if [ "$distro" = "ubuntu" ]; then + # Untested since ~2022, when firefox became a snap too and we had enough + # TODO: Use ungoogled-chromium + # Non-snap chromium + cat > "${root}/etc/apt/sources.list.d/xalt7x-${distro}-chromium-deb-vaapi-${release}.list" <<-EOF + deb http://ppa.launchpad.net/xalt7x/chromium-deb-vaapi/${distro} ${release} main + # deb-src http://ppa.launchpad.net/xalt7x/chromium-deb-vaapi/${distro} ${release} main + EOF + + # pin chromium + cat > "${root}/etc/apt/preferences.d/pin-xalt7x-chromium-deb-vaapi" <<-EOF + Package: * + Pin: release o=LP-PPA-xalt7x-chromium-deb-vaapi + Pin-Priority: 1337 + EOF + + # MESA + cat > "${root}/etc/apt/sources.list.d/mesa-new.list" <<-EOF + deb http://ppa.launchpad.net/ernstp/mesarc/ubuntu ${release} main + EOF +fi + +# As some scripts might do commits +cat > "${root}/root/.gitconfig" <<END +[user] + email = you@example.com + name = Your Name +END + +# Now that we fiddled with package sources, refresh db +run apt update || perror "apt update after resetting package sources failed" +# And run an upgrade just to be sure +run apt -o Dpkg::Options::='--force-confold' -o Dpkg::Options::='--force-confdef' -y full-upgrade \ + || perror "Could not full-upgrade" +# Then install all packages read from the configs passed on cmdline +run apt -o Dpkg::Options::='--force-confold' -o Dpkg::Options::='--force-confdef' install -y $pkgs_full \ + || perror "Could not install apt list" +run apt -o Dpkg::Options::='--force-confold' -o Dpkg::Options::='--force-confdef' install -y --no-install-recommends $pkgs_lean \ + || perror "Could not install no recommends list" + +fix_resolv + +# Prepare mltk +run git clone --depth 1 git://git.openslx.org/openslx-ng/mltk.git /mltk \ + || perror "Could not clone mltk" + +# Insert our overrides for mltk +echo "$MLTK_CONFIG" > "${root}/mltk/config" + +mkdir -p "${root}/boot" + +# Figure out which kernel config to use as a base +if [ -n "${kernel_base_config}" ]; then + if [ -s "${ROOT_DIR}/kernel.config" ]; then + echo "Already have an override kernel config, not downloading ${kernel_base_config}" + sleep 2 + else + wget -O "${ROOT_DIR}/kernel.config" "${kernel_base_config}" \ + || perror "Could not get kernel base config from ${kernel_base_config}" + fi +fi + +cp "${ROOT_DIR}/kernel.config" "${root}/boot/config-mltk" \ + || cp "/boot/config-$(uname -r)" "${root}/boot/config-$(uname -r)" \ + || echo "Did not copy any kernel config over..." + +# Finally, build mltk stuff +run /mltk/mltk stage4 -i -b kernel || perror "Could not mltk kernel" # without -d for noninteractive +run /mltk/mltk stage4 -b -d -i || perror "Could not mltk stage 4" +run /mltk/mltk vmware-addon -b -d -i || perror "Could not mltk vmware" +run /mltk/mltk vmware-legacy-addon -b -d -i || perror "Could not mltk vmware-legacy" +run /mltk/mltk nvidia-libs@NVIDIA_VERSIONS -b -d -i || perror "Could not mltk nvidia-libs" +run /mltk/mltk qemu -b -d -i || perror "Could not mltk qemu" + +# Locale is messed up by this point +# TODO: Configurable? +cat > "${root}/etc/locale.gen" <<EOF +de_DE.UTF-8 UTF-8 +en_US.UTF-8 UTF-8 +C.UTF-8 UTF-8 +EOF +run update-locale LANG=C.UTF-8 +run locale-gen +run fc-cache -v -f -r -s + +# Another stupid hack: Force our wallpaper for xfce by replacing every wallpaper with ours +for f in "${root}/usr/share/backgrounds/xfce/"*; do + [ -f "$f" ] || continue + ln -nfs "/usr/share/wallpapers/bwLehrpool/contents/images/1920x1080.png" "$f" +done + +## Not needed currently/anymore? +# Use old iptables for now, not the nft wrapper, as physdev matching is broken there +#run update-alternatives --set iptables /usr/sbin/iptables-legacy + +# Disable annoying motd stuff, is unfortunately part of base pam package on ubuntu +# and the firstlogin disclaimer cannot be disabled? +run sed -i '/pam_motd/d' /etc/pam.d/sshd /etc/pam.d/login || perror "Could not disable pam_motd" + +# Copy static stuff we ship +rsync -avHAX --chown=0:0 "${ROOT_DIR}/data/" "${root}/" || perror "Could not sync data dir" + +# Disable services we don't want or need +# TODO: udisks2 and numad are currently hard-coded here, because we don't want to mask them. +# They should still be triggerable when they're actually needed, i.e. a native session +run systemctl disable $disabled_services udisks2.service numad.service +run systemctl mask $disabled_services +for s in $disabled_services udisks2.service; do + if [[ "$s" == *.* ]]; then + rm -- "${root}/"etc/systemd/system/*.wants/"$s" + else + rm -- "${root}/"etc/systemd/system/*.wants/"$s".service + fi +done + +# Now create disk image + +# Get size of FS +shopt -s extglob +fs_size=$( du -s -BM "${root}"/!(mltk|systemd-init|boot|proc|sys|dev|run|tmp) | awk '{a+=$1}END{print a}' ) + +if (( fs_size < 1000 )) || (( fs_size > 50000 )); then + perror "implausible rootfs size: $fs_size MB" +fi + +# Leave 500MB buffer space +un="${base}/uncompressed.qcow2" +cmp="/tmp/compressed.qcow2" +qemu-img create -f qcow2 "$un" "$(( fs_size + 500 ))M" \ + || perror "Could not create uncompressed qcow2" + +qemu-nbd -c /dev/nbd3 --discard=unmap --detect-zeroes=unmap "$un" || perror "qemu-nbd fail" +echo -e "n\n\n\n\n\nc\nSLX_SYS\nw\ny\n" | gdisk /dev/nbd3 || perror "gdisk failed" +partprobe /dev/nbd3 +sleep 1 +[ -b "/dev/nbd3p1" ] || perror "NBD partition not found" + +mkfs.ext4 /dev/nbd3p1 || perror "mkfs.ext4 failed" +mount "/dev/nbd3p1" "${base}/mnt" || perror "Mount failed" + +# TODO: Configurable blacklist +rsync -avHAX \ + --exclude="/dev/*" \ + --exclude="/sys/*" \ + --exclude="/proc/*" \ + --exclude="/run/*" \ + --exclude="/boot" \ + --exclude="/snap/*" \ + --exclude="/mltk" \ + --exclude="/systemd-init" \ + --exclude="*~" \ + --exclude="*.tmp" \ + --exclude=".*.swp" \ + --include="/var/log/**/" \ + --exclude="/var/log/**" \ + --include="/var/cache/**/" \ + --include="/var/cache/fontconfig/**" \ + --include="/var/cache/ldconfig/**" \ + --exclude="/var/cache/**" \ + --include="/var/spool/**/" \ + --exclude="/var/spool/**" \ + --exclude="/addon-init" \ + --exclude="/etc/apt/apt.conf.d/01proxy" \ + --exclude="/etc/resolv.conf" \ + --include="/root/.bashrc" \ + --exclude="/root/**" \ + --exclude="/etc/init.d/kexec" \ + --exclude="/etc/init.d/kexec-load" \ + --exclude="/usr/share/xsessions/i3-with-shmlog.desktop" \ + --exclude="/usr/share/xsessions/lightdm-xsession.desktop" \ + --exclude="/usr/lib/udev/rules.d/*-hwclock.rules" \ + --exclude="/usr/lib/udev/rules.d/*-alsa-restore.rules" \ + --exclude="/tmp/**" \ + --exclude="/etc/krb5.conf" \ + "${root}/" "${base}/mnt/" \ + || perror "rsync failed" + +echo "Unmounting container" +umount "${base}/mnt" || perror "Unmount Failed" +sync +echo "Shutting down qemu-nbd" +qemu-nbd -d /dev/nbd3 || perror "closing qemu-nbd failed" +sync + +# Convert in background since it's slow +echo "Compressing qcow2 in background job" +qcow_progress="$base/qcow-log" +# -o compression_type=zstd +qemu-img convert -W -m 16 -p -O qcow2 -c "$un" "$cmp" &> "$qcow_progress" & +qcow_pid="$!" + +# Dracut +# Build initramfs + +# Do we have zstd? +compress= +if grep -qF 'CONFIG_RD_ZSTD=y' "${root}/mltk/tmp/work/kernel/ksrc/.config" \ + && command -v zstd; then + compress="zstd -19 -q -T0" +elif grep -qF 'CONFIG_RD_LZ4=y' "${root}/mltk/tmp/work/kernel/ksrc/.config" \ + && command -v lz4; then + compress="lz4" +elif grep -qF 'CONFIG_RD_GZIP=y' "${root}/mltk/tmp/work/kernel/ksrc/.config" \ + && command -v gzip; then + compress="gzip" +fi + +if [ -n "$compress" ]; then + echo "Using compression for initrd: $compress" + compress="--compress $compress" +else + echo "Will not compress initrd. Either not supported by kernel, or compression tool missing." + compress="--no-compress" +fi + +mkdir -p "${root}/systemd-init" +wget -O "${root}/systemd-init/build-initramfs.sh" \ + "https://git.openslx.org/openslx-ng/systemd-init.git/plain/build-initramfs.sh" \ + || perror "Could not download systemd-init script" +chmod +x "${root}/systemd-init/build-initramfs.sh" + +long_debug= # "--debug" +for ver in "${root}/lib/"modules/*-openslx*; do + # Workaround for xloop build *sometimes* failing. It sometimes claims it can't copy + # a file that's definitely there, but that's cmake for you I guess. + for tries in 1 2 FAIL; do + if [ "$tries" = "FAIL" ]; then + perror "dracut stuff failed" + fi + run /systemd-init/build-initramfs.sh $long_debug --update --file-path "/systemd-init/initramfs-${ver##*/}" \ + --kernel-version "${ver##*/}" --kernel-headers /mltk/tmp/work/kernel/ksrc/ \ + --qcow-handler xloop --all-microcode \ + - \ + --add 'slx-clock slx-addons slx-runmode slx-uuid slx-splash slx-drm slx-ssl' \ + --install '/usr/sbin/mii-tool /usr/sbin/ethtool' \ + --omit crypt --omit-drivers nvidiafb "$compress" \ + && break + done + mkdir -p "${base}/out-${ver##*/}" + # Move initrd to destination + mv -f -- "${root}/systemd-init/initramfs-${ver##*/}" \ + "${base}/out-${ver##*/}/initramfs-stage31" \ + || perror "Error copying initrd to destination" + # Move kernel to destination + mv -f -- "${root}/mltk/var/builds/kernel/kernel" \ + "${base}/out-${ver##*/}/kernel" \ + || perror "Error moving kernel to destination" +done + +# Wait for qemu-img to finish compression +tail -f "$qcow_progress" & +cat_pid="$!" +wait "$qcow_pid" || pwarning "Compressing final qcow2 failed" +kill "$cat_pid" +rm -f -- "$qcow_progress" +wait + +exit 0 + diff --git a/configs/base/disabled_services b/configs/base/disabled_services new file mode 100644 index 0000000..053a369 --- /dev/null +++ b/configs/base/disabled_services @@ -0,0 +1,58 @@ +NetworkManager +NetworkManager-wait-online +alsa-restore +anacron +anacron.timer +apparmor +apport +apport-autoreport +apt-daily +apt-daily-upgrade +apt-daily-upgrade.timer +apt-daily.timer +dnsmasq.service +dpkg-db-backup.timer +e2scrub_all.service +e2scrub_all.timer +e2scrub_reap.service +exim4-base.timer +exim4.service +fstrim.timer +grub-common +iscsid.socket +lvm2-lvmpolld.socket +lvm2-monitor.service +man-db.timer +motd-news.timer +networkd-dispatcher +nmbd +ondemand.service +openarena-server +smartd +smartmontools.service +smbd +sssd-nss.socket +sssd-pam-priv.socket +sssd-pam.socket +systemd-ask-password-console.path +systemd-ask-password-console.service +systemd-ask-password-wall.path +systemd-backlight@.service +systemd-fsck-root.service +systemd-journal-flush +systemd-random-seed.service +systemd-remount-fs.service +systemd-resolved.service +systemd-sysusers.service +systemd-timesyncd.service +systemd-tmpfiles-clean +systemd-tmpfiles-clean.timer +unattended-upgrades +winbind +wpa_supplicant +zfs-import.target +zfs-load-module.service +zfs-share.service +zfs-volume-wait.service +zfs-volumes.target +zfs.target diff --git a/configs/base/pkgs_dummy b/configs/base/pkgs_dummy new file mode 100644 index 0000000..76cf41b --- /dev/null +++ b/configs/base/pkgs_dummy @@ -0,0 +1,11 @@ +anacron +packagekit +plasma-discover +plymouth +popularity-contest +snapd +ubuntu-release-upgrader-core +ubuntu-release-upgrader-gtk +unattended-upgrades +update-manager +update-manager-core diff --git a/configs/base/pkgs_full b/configs/base/pkgs_full new file mode 100644 index 0000000..eadae8f --- /dev/null +++ b/configs/base/pkgs_full @@ -0,0 +1,5 @@ +cron +curl +git +htop +i3 diff --git a/configs/base/pkgs_lean b/configs/base/pkgs_lean new file mode 100644 index 0000000..830f5f4 --- /dev/null +++ b/configs/base/pkgs_lean @@ -0,0 +1,26 @@ +apt-utils +autoconf +automake +bc +calc +cmake +cpio +dmsetup +ethtool +iputils-ping +kbd +kmod +libkmod-dev +locales +lsof +lz4 +m4 +neovim +net-tools +nfs-common +ntpdate +pkg-config +pulseaudio +software-properties-common +xxd +zstd diff --git a/configs/browser-debian/pkgs_lean b/configs/browser-debian/pkgs_lean new file mode 100644 index 0000000..67f9959 --- /dev/null +++ b/configs/browser-debian/pkgs_lean @@ -0,0 +1,2 @@ +chromium +firefox-esr diff --git a/configs/browser-ubuntu/pkgs_lean b/configs/browser-ubuntu/pkgs_lean new file mode 100644 index 0000000..6821f12 --- /dev/null +++ b/configs/browser-ubuntu/pkgs_lean @@ -0,0 +1,2 @@ +chromium-browser +firefox diff --git a/configs/tools-base/pkgs_full b/configs/tools-base/pkgs_full new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/configs/tools-base/pkgs_full diff --git a/configs/tools-base/pkgs_lean b/configs/tools-base/pkgs_lean new file mode 100644 index 0000000..a5a0687 --- /dev/null +++ b/configs/tools-base/pkgs_lean @@ -0,0 +1,26 @@ +bash-completion +bridge-utils +build-essential +dbus-user-session +dnsutils +e2fslibs +git +gparted +htop +iotop +jq +lm-sensors +ltrace +m4 +man +net-tools +nmap +ntfs-3g +screen +smartmontools +strace +tcpdump +vim +wireshark +xclip +zenity diff --git a/configs/xfce4/pkgs_lean b/configs/xfce4/pkgs_lean new file mode 100644 index 0000000..1179414 --- /dev/null +++ b/configs/xfce4/pkgs_lean @@ -0,0 +1,20 @@ +adwaita-icon-theme +evince +fonts-noto-color-emoji +fonts-noto-core +gnome-icon-theme +greybird-gtk-theme +gvfs +gvfs-backends +gvfs-fuse +hicolor-icon-theme +intel-media-va-driver +mesa-va-drivers +mousepad +python3-lxml +ristretto +udisks2 +xfce4 +xfce4-goodies +xfce4-power-manager +xfce4-terminal diff --git a/data/etc/apt/trusted.gpg.d/ernstp_ubuntu_mesarc.gpg b/data/etc/apt/trusted.gpg.d/ernstp_ubuntu_mesarc.gpg Binary files differnew file mode 100644 index 0000000..2ed2301 --- /dev/null +++ b/data/etc/apt/trusted.gpg.d/ernstp_ubuntu_mesarc.gpg diff --git a/data/etc/dconf/db/local.d/01-bwlehrpool b/data/etc/dconf/db/local.d/01-bwlehrpool new file mode 100644 index 0000000..86f3342 --- /dev/null +++ b/data/etc/dconf/db/local.d/01-bwlehrpool @@ -0,0 +1,51 @@ +# set default background +[org/gnome/desktop/background] +picture-uri='file:///usr/share/backgrounds/bwlp-1920x1080.png' +picture-options='zoom' +primary-color='000000' +secondary-color='000000' + +# disable screensaver and lock +# but also set default picture just in case +[org/gnome/desktop/screensaver] +idle-activation-enabled=false +lock-enabled=false +ubuntu-lock-on-suspend=false +picture-uri='file:///usr/share/backgrounds/bwlp-1920x1080.png' +picture-options='zoom' +primary-color='000000' +secondary-color='000000' + +# disable lockscreen +[org/gnome/desktop/lockdown] +disable-lock-screen=true + +# ensure german keyboard layout on gnome-shell +[org/gnome/desktop/input-sources] +sources=[('xkb', 'de')] + +# disable automatic updates of gnome software +[org/gnome/software] +download-updates=false +download-updates-notify=false + +# disable icons on desktop for mounted shares +[org/gnome/nautilus/desktop] +volumes-visible=false + +# disable different power settings +[org/gnome/settings-daemon/plugins/power] +idle-dim=false +idle-brightness=100 +sleep-inactive-ac-timeout=0 +sleep-inactive-battery-timeout=0 +sleep-inactive-ac-type='nothing' +sleep-inactive-battery-type='nothing' + +# disable display suspend after idle-time (uint32 !!!) +[org/gnome/desktop/session] +idle-delay=uint32 0 + +# set favorites in dock +[org/gnome/shell] +favorite-apps=[ 'org.gnome.Nautilus.desktop', 'chromium-browser.desktop', 'firefox.desktop', 'libreoffice-writer.desktop', 'libreoffice-calc.desktop', 'libreoffice-impress.desktop', 'org.gnome.Terminal.desktop', 'gnome-control-center.desktop' ] diff --git a/data/etc/dconf/profile/user b/data/etc/dconf/profile/user new file mode 100644 index 0000000..aca0641 --- /dev/null +++ b/data/etc/dconf/profile/user @@ -0,0 +1,2 @@ +user-db:user +system-db:local diff --git a/data/etc/default/locale b/data/etc/default/locale new file mode 100644 index 0000000..cf1a6d5 --- /dev/null +++ b/data/etc/default/locale @@ -0,0 +1,2 @@ +LANG="de_DE.UTF-8" +LANGUAGE="de_DE:de" diff --git a/data/etc/docker/daemon.json b/data/etc/docker/daemon.json new file mode 100644 index 0000000..b887738 --- /dev/null +++ b/data/etc/docker/daemon.json @@ -0,0 +1,5 @@ +{ + "data-root": "/tmp/virt/docker", + "storage-driver": "overlay2", + "userns-remap": "default" +} diff --git a/data/etc/firefox/policies/policies.json b/data/etc/firefox/policies/policies.json new file mode 100644 index 0000000..a3c4038 --- /dev/null +++ b/data/etc/firefox/policies/policies.json @@ -0,0 +1,43 @@ +{ + "policies": { + "NoDefaultBookmarks": true, + "ExtensionSettings": { + "uBlock0@raymondhill.net": { + "installation_mode": "force_installed", + "install_url": "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi" + } + }, + "FirefoxHome": { + "Search": true, + "TopSites": false, + "SponsoredTopSites": false, + "Highlights": false, + "Pocket": false, + "SponsoredPocket": false, + "Snippets": false + }, + "FirefoxSuggest": { + "WebSuggestions": false, + "SponsoredSuggestions": false, + "ImproveSuggest": false + }, + "AppAutoUpdate": false, + "DisableAppUpdate": true, + "DisablePocket": true, + "DisableProfileImport": true, + "DontCheckDefaultBrowser": true, + "OverrideFirstRunPage": "", + "OverridePostUpdatePage": "", + "PromptForDownloadLocation": true, + "DisableTelemetry": true, + "SearchEngines": { + "Default": "DuckDuckGo" + }, + "UserMessaging": { + "ExtensionRecommendations": false, + "FeatureRecommendations": false, + "UrlbarInterventions": false, + "SkipOnboarding": true + } + } +} diff --git a/data/etc/i3/config b/data/etc/i3/config new file mode 100644 index 0000000..49b3bb1 --- /dev/null +++ b/data/etc/i3/config @@ -0,0 +1,199 @@ +# i3 config file (v4) +# +# Please see https://i3wm.org/docs/userguide.html for a complete reference! +# +# This config file uses keycodes (bindsym) and was written for the QWERTY +# layout. +# +# To get a config file with the same key positions, but for your current +# layout, use the i3-config-wizard +# + +# Font for window titles. Will also be used by the bar unless a different font +# is used in the bar {} block below. +font pango:monospace 8 + +# This font is widely installed, provides lots of unicode glyphs, right-to-left +# text rendering and scalability on retina/hidpi displays (thanks to pango). +font pango:DejaVu Sans Mono 8 + +# Use pactl to adjust volume in PulseAudio. +set $refresh_i3status killall -SIGUSR1 i3status +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status +bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status + +# use these keys for focus, movement, and resize directions when reaching for +# the arrows is not convenient +set $up l +set $down k +set $left j +set $right semicolon + +# use Mouse+Mod1 to drag floating windows to their wanted position +floating_modifier Mod1 + +# move tiling windows via drag & drop by left-clicking into the title bar, +# or left-clicking anywhere into the window while holding the floating modifier. +tiling_drag modifier titlebar + +# start a terminal +bindsym Mod1+Return exec i3-sensible-terminal + +# kill focused window +bindsym Mod1+Shift+q kill + +# start dmenu (a program launcher) +bindsym Mod1+d exec --no-startup-id dmenu_run +# A more modern dmenu replacement is rofi: +# bindsym Mod1+d exec "rofi -modi drun,run -show drun" +# There also is i3-dmenu-desktop which only displays applications shipping a +# .desktop file. It is a wrapper around dmenu, so you need that installed. +# bindsym Mod1+d exec --no-startup-id i3-dmenu-desktop + +# change focus +bindsym Mod1+$left focus left +bindsym Mod1+$down focus down +bindsym Mod1+$up focus up +bindsym Mod1+$right focus right + +# alternatively, you can use the cursor keys: +bindsym Mod1+Left focus left +bindsym Mod1+Down focus down +bindsym Mod1+Up focus up +bindsym Mod1+Right focus right + +# move focused window +bindsym Mod1+Shift+$left move left +bindsym Mod1+Shift+$down move down +bindsym Mod1+Shift+$up move up +bindsym Mod1+Shift+$right move right + +# alternatively, you can use the cursor keys: +bindsym Mod1+Shift+Left move left +bindsym Mod1+Shift+Down move down +bindsym Mod1+Shift+Up move up +bindsym Mod1+Shift+Right move right + +# split in horizontal orientation +bindsym Mod1+h split h + +# split in vertical orientation +bindsym Mod1+v split v + +# enter fullscreen mode for the focused container +bindsym Mod1+f fullscreen toggle + +# change container layout (stacked, tabbed, toggle split) +bindsym Mod1+s layout stacking +bindsym Mod1+w layout tabbed +bindsym Mod1+e layout toggle split + +# toggle tiling / floating +bindsym Mod1+Shift+space floating toggle + +# change focus between tiling / floating windows +bindsym Mod1+space focus mode_toggle + +# focus the parent container +bindsym Mod1+a focus parent + +# focus the child container +#bindsym Mod1+d focus child + +# move the currently focused window to the scratchpad +bindsym Mod1+Shift+minus move scratchpad + +# Show the next scratchpad window or hide the focused scratchpad window. +# If there are multiple scratchpad windows, this command cycles through them. +bindsym Mod1+minus scratchpad show + +# Define names for default workspaces for which we configure key bindings later on. +# We use variables to avoid repeating the names in multiple places. +set $ws1 "1" +set $ws2 "2" +set $ws3 "3" +set $ws4 "4" +set $ws5 "5" +set $ws6 "6" +set $ws7 "7" +set $ws8 "8" +set $ws9 "9" +set $ws10 "10" + +# switch to workspace +bindsym Mod1+1 workspace number $ws1 +bindsym Mod1+2 workspace number $ws2 +bindsym Mod1+3 workspace number $ws3 +bindsym Mod1+4 workspace number $ws4 +bindsym Mod1+5 workspace number $ws5 +bindsym Mod1+6 workspace number $ws6 +bindsym Mod1+7 workspace number $ws7 +bindsym Mod1+8 workspace number $ws8 +bindsym Mod1+9 workspace number $ws9 +bindsym Mod1+0 workspace number $ws10 + +# move focused container to workspace +bindsym Mod1+Shift+1 move container to workspace number $ws1 +bindsym Mod1+Shift+2 move container to workspace number $ws2 +bindsym Mod1+Shift+3 move container to workspace number $ws3 +bindsym Mod1+Shift+4 move container to workspace number $ws4 +bindsym Mod1+Shift+5 move container to workspace number $ws5 +bindsym Mod1+Shift+6 move container to workspace number $ws6 +bindsym Mod1+Shift+7 move container to workspace number $ws7 +bindsym Mod1+Shift+8 move container to workspace number $ws8 +bindsym Mod1+Shift+9 move container to workspace number $ws9 +bindsym Mod1+Shift+0 move container to workspace number $ws10 + +# reload the configuration file +bindsym Mod1+Shift+c reload +# restart i3 inplace (preserves your layout/session, can be used to upgrade i3) +bindsym Mod1+Shift+r restart +# exit i3 (logs you out of your X session) +bindsym Mod1+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'" + +# resize window (you can also use the mouse for that) +mode "resize" { + # These bindings trigger as soon as you enter the resize mode + + # Pressing left will shrink the window’s width. + # Pressing right will grow the window’s width. + # Pressing up will shrink the window’s height. + # Pressing down will grow the window’s height. + bindsym $left resize shrink width 10 px or 10 ppt + bindsym $down resize grow height 10 px or 10 ppt + bindsym $up resize shrink height 10 px or 10 ppt + bindsym $right resize grow width 10 px or 10 ppt + + # same bindings, but for the arrow keys + bindsym Left resize shrink width 10 px or 10 ppt + bindsym Down resize grow height 10 px or 10 ppt + bindsym Up resize shrink height 10 px or 10 ppt + bindsym Right resize grow width 10 px or 10 ppt + + # back to normal: Enter or Escape or Mod1+r + bindsym Return mode "default" + bindsym Escape mode "default" + bindsym Mod1+r mode "default" +} + +bindsym Mod1+r mode "resize" + +# Start i3bar to display a workspace bar (plus the system information i3status +# finds out, if available) +bar { + status_command i3status +} + +####################################################################### +# automatically start i3-config-wizard to offer the user to create a +# keysym-based config which used their favorite modifier (alt or windows) +# +# i3-config-wizard will not launch if there already is a config file +# in ~/.config/i3/config (or $XDG_CONFIG_HOME/i3/config if set) or +# ~/.i3/config. +# +# Please remove the following exec line: +####################################################################### +exec i3-config-wizard diff --git a/data/etc/i3status.conf b/data/etc/i3status.conf new file mode 100644 index 0000000..a490f88 --- /dev/null +++ b/data/etc/i3status.conf @@ -0,0 +1,74 @@ +# i3status configuration file. +# see "man i3status" for documentation. + +# It is important that this file is edited as UTF-8. +# The following line should contain a sharp s: +# ß +# If the above line is not correctly displayed, fix your editor first! + +general { + colors = true + interval = 5 +} + +order += "read_file hostname" +order += "ipv6" +order += "wireless _first_" +order += "ethernet br0" +order += "read_file dnbd3" +order += "battery all" +order += "disk /" +order += "load" +order += "memory" +order += "tztime local" + +ipv6 { + format_down = "" +} + +wireless _first_ { + format_up = "W: (%quality at %essid, %bitrate) %ip" + format_down = "" +} + +ethernet br0 { + format_up = "br0: %ip (%speed)" + format_down = "Network down" +} + +read_file hostname { + color_good = "#ffffff" + path = "/etc/hostname" +} + +read_file dnbd3 { + color_good = "#ffffff" + path = "/sys/block/dnbd0/net/cur_server_addr" + format = "DNBD3: %content" + format_bad = "No DNBD3" +} + +battery all { + format = "%status %percentage %remaining" + format_down = "" +} + +disk "/" { + format = "Temp free: %avail" + low_threshold = 2 + threshold_type = gbytes_free +} + +load { + format = "%1min" +} + +memory { + format = "RAM: [ %used | %available ]" + threshold_degraded = "1G" + format_degraded = "MEMORY < %available" +} + +tztime local { + format = "%Y-%m-%d %H:%M:%S" +} diff --git a/data/etc/profile.d/10-autostart.sh b/data/etc/profile.d/10-autostart.sh new file mode 100644 index 0000000..3a4cae0 --- /dev/null +++ b/data/etc/profile.d/10-autostart.sh @@ -0,0 +1,83 @@ +#!/bin/ash + +TEMP_HOME_DIR="$HOME" +PERSISTENT_HOME_DIR="$HOME/PERSISTENT" + +# Use /etc/skel/* files to create default config files for users that do not have any +for file in .bashrc .profile .vimrc .gitconfig .local/share/applications/mimeapps.list; do + [ -e "$TEMP_HOME_DIR/$file" ] && continue + if [ "x$(dirname "$file")" != "x." ]; then + mkdir -p "$TEMP_HOME_DIR/$(dirname "$file")" + fi + if [ -e "$PERSISTENT_HOME_DIR/$file" ]; then + ln -s "$PERSISTENT_HOME_DIR/$file" "$TEMP_HOME_DIR/$file" + continue + fi + if [ -e "/etc/skel/$file" ]; then + if [ -d "$PERSISTENT_HOME_DIR" ]; then + cp "/etc/skel/$file" "$PERSISTENT_HOME_DIR/$file" + ln -s "$PERSISTENT_HOME_DIR/$file" "$TEMP_HOME_DIR/$file" + else + cp "/etc/skel/$file" "$TEMP_HOME_DIR/$file" + fi + fi +done + + +if [ -d "$PERSISTENT_HOME_DIR" ]; then + + # Persistent home was mounted, take care of some convenience directories + for file in .vim .config/htop .config/openslx .config/xfce4; do + [ -e "$TEMP_HOME_DIR/$file" ] && continue + if [ "x$(dirname "$file")" != "x." ]; then + mkdir -p "$TEMP_HOME_DIR/$(dirname "$file")" + fi + if [ ! -d "$PERSISTENT_HOME_DIR/$file" ]; then + mkdir -p "$PERSISTENT_HOME_DIR/$file" + fi + ln -s "$PERSISTENT_HOME_DIR/$file" "$TEMP_HOME_DIR/$file" + done + + # configure XDG directories according to $TEMP_HOME_DIR/.openslx/shares + if [ -e "${TEMP_HOME_DIR}/.openslx/shares" ]; then + . "${TEMP_HOME_DIR}/.openslx/shares" + + ## Documents + TARGET_DIR="$TEMP_HOME_DIR" + [ "$SHARE_DOCUMENTS" = "1" ] && TARGET_DIR="$PERSISTENT_HOME_DIR" + echo "XDG_DOCUMENTS_DIR=\"$TARGET_DIR/Documents\"" + echo "XDG_TEMPLATES_DIR=\"$TARGET_DIR/Templates\"" + + ## Downloads + TARGET_DIR="$TEMP_HOME_DIR" + [ "$SHARE_DOWNLOADS" = "1" ] && TARGET_DIR="$PERSISTENT_HOME_DIR" + echo "XDG_DOWNLOAD_DIR=\"$TARGET_DIR/Downloads\"" + + ## Desktop + TARGET_DIR="$TEMP_HOME_DIR" + [ "$SHARE_DESKTOP" = "1" ] && TARGET_DIR="$PERSISTENT_HOME_DIR" + echo "XDG_DESKTOP_DIR=\"$TARGET_DIR/Desktop\"" + + # Music/Pictures/Videos + TARGET_DIR="$TEMP_HOME_DIR" + [ "$SHARE_MEDIA" = "1" ] && TARGET_DIR="$PERSISTENT_HOME_DIR" + echo "XDG_MUSIC_DIR=\"$TARGET_DIR/Music\"" + echo "XDG_PICTURES_DIR=\"$TARGET_DIR/Pictures\"" + echo "XDG_VIDEOS_DIR=\"$TARGET_DIR/Videos\"" + + # Publicshare, w/e that is + TARGET_DIR="$TEMP_HOME_DIR" + [ "$SHARE_OTHER" = "1" ] && TARGET_DIR="$PERSISTENT_HOME_DIR" + echo "XDG_PUBLICSHARE_DIR=\"$TARGET_DIR/Public\"" + fi > "$TEMP_HOME_DIR/.config/user-dirs.dirs" + + # Check if user has autostart script and run it (so they can create more symlinks etc.) + if [ -x "$PERSISTENT_HOME_DIR/AUTOSTART" ]; then + if cd "$TEMP_HOME_DIR"; then + "$PERSISTENT_HOME_DIR/AUTOSTART" + cd - >/dev/null 2>&1 + fi + fi + +fi + diff --git a/data/etc/profile.d/20-default-xfce4-panel.sh b/data/etc/profile.d/20-default-xfce4-panel.sh new file mode 100644 index 0000000..6454c84 --- /dev/null +++ b/data/etc/profile.d/20-default-xfce4-panel.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +default_panel_file="/etc/xdg/xfce4/panel/default.xml" +if [ ! -e "$default_panel_file" ]; then + exit 1 +fi + +[ -z "$HOME" ] && HOME=$( getent passwd "$(id -u $PAM_USER)" | awk -F: '{print $6}' ) + +TARGET_HOME_DIR="$HOME" +[ -d "$HOME/PERSISTENT" ] && TARGET_HOME_DIR="$HOME/PERSISTENT" + +if [ ! -e "${TARGET_HOME_DIR}/.config/xfce4/panel/default.xml" ]; then + mkdir -p "${TARGET_HOME_DIR}/.config/xfce4/panel" + cp -f -- "$default_panel_file" "${TARGET_HOME_DIR}/.config/xfce4/panel/" +fi diff --git a/data/etc/udev/rules.d/99-ignore-slx-partitions.rules b/data/etc/udev/rules.d/99-ignore-slx-partitions.rules new file mode 100644 index 0000000..da45742 --- /dev/null +++ b/data/etc/udev/rules.d/99-ignore-slx-partitions.rules @@ -0,0 +1,3 @@ +SUBSYSTEM=="block", ENV{ID_PART_ENTRY_NAME}=="SLX_SYS|OpenSLX-ID44|OpenSLX-ID45", ENV{UDISKS_IGNORE}="1" +SUBSYSTEM=="block", ENV{ID_PART_ENTRY_UUID}=="87f86132-ff94-4987-b250-444444444444|87f86132-ff94-4987-b250-454545454545", ENV{UDISKS_IGNORE}="1" +SUBSYSTEM=="block", ENV{ID_PART_ENTRY_TYPE}=="0x44|0x45", ENV{UDISKS_IGNORE}="1" diff --git a/data/etc/xdg/baloofilerc b/data/etc/xdg/baloofilerc new file mode 100644 index 0000000..1735f7a --- /dev/null +++ b/data/etc/xdg/baloofilerc @@ -0,0 +1,2 @@ +[Basic Settings] +Indexing-Enabled=false diff --git a/data/etc/xdg/kded5rc b/data/etc/xdg/kded5rc new file mode 100644 index 0000000..fbf4be2 --- /dev/null +++ b/data/etc/xdg/kded5rc @@ -0,0 +1,53 @@ +[Module-appmenu] +autoload=true + +[Module-baloosearchmodule] +autoload=false + +[Module-bluedevil] +autoload=false + +[Module-colorcorrectlocationupdater] +autoload=false + +[Module-device_automounter] +autoload=true + +[Module-freespacenotifier] +autoload=false + +[Module-keyboard] +autoload=true + +[Module-khotkeys] +autoload=true + +[Module-kscreen] +autoload=false + +[Module-ksysguard] +autoload=true + +[Module-ktimezoned] +autoload=true + +[Module-kwrited] +autoload=true + +[Module-networkstatus] +autoload=true + +[Module-proxyscout] +autoload=false + +[Module-remotenotifier] +autoload=false + +[Module-solidautoeject] +autoload=true + +[Module-statusnotifierwatcher] +autoload=true + +[Module-touchpad] +autoload=true diff --git a/data/etc/xdg/ksmserverrc b/data/etc/xdg/ksmserverrc new file mode 100644 index 0000000..f213401 --- /dev/null +++ b/data/etc/xdg/ksmserverrc @@ -0,0 +1,7 @@ +[General] +confirmLogout=false +excludeApps= +loginMode=restorePreviousLogout +offerShutdown=false +screenCount=1 +shutdownType=0 diff --git a/data/etc/xdg/xfce4/kiosk/kioskrc b/data/etc/xdg/xfce4/kiosk/kioskrc new file mode 100644 index 0000000..a98479c --- /dev/null +++ b/data/etc/xdg/xfce4/kiosk/kioskrc @@ -0,0 +1,7 @@ +[xfce4-session] +CustomizeSplash=NONE +CustomizeChooser=NONE +CustomizeLogout=NONE +Shutdown=%wheel +CustomizeSecurity=NONE +SaveSession=NONE diff --git a/data/etc/xdg/xfce4/panel/default.xml b/data/etc/xdg/xfce4/panel/default.xml new file mode 100644 index 0000000..3fb45d4 --- /dev/null +++ b/data/etc/xdg/xfce4/panel/default.xml @@ -0,0 +1,120 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<channel name="xfce4-panel" version="1.0"> + <property name="configver" type="int" value="2"/> + <property name="panels" type="array"> + <value type="int" value="1"/> + <value type="int" value="2"/> + <property name="panel-1" type="empty"> + <property name="position" type="string" value="p=6;x=0;y=0"/> + <property name="length" type="uint" value="100"/> + <property name="position-locked" type="bool" value="true"/> + <property name="icon-size" type="uint" value="16"/> + <property name="size" type="uint" value="26"/> + <property name="plugin-ids" type="array"> + <value type="int" value="1"/> + <value type="int" value="2"/> + <value type="int" value="3"/> + <value type="int" value="4"/> + <value type="int" value="5"/> + <value type="int" value="6"/> + <value type="int" value="7"/> + <value type="int" value="8"/> + <value type="int" value="9"/> + <value type="int" value="11"/> + <value type="int" value="12"/> + <value type="int" value="13"/> + <value type="int" value="14"/> + </property> + </property> + <property name="panel-2" type="empty"> + <property name="autohide-behavior" type="uint" value="1"/> + <property name="position" type="string" value="p=10;x=0;y=0"/> + <property name="position-locked" type="bool" value="true"/> + <property name="size" type="uint" value="48"/> + <property name="plugin-ids" type="array"> + <value type="int" value="15"/> + <value type="int" value="16"/> + <value type="int" value="17"/> + <value type="int" value="18"/> + <value type="int" value="19"/> + <value type="int" value="20"/> + <value type="int" value="21"/> + <value type="int" value="22"/> + </property> + </property> + </property> + <property name="plugins" type="empty"> + <property name="plugin-1" type="string" value="applicationsmenu"/> + <property name="plugin-2" type="string" value="tasklist"> + <property name="grouping" type="uint" value="1"/> + </property> + <property name="plugin-3" type="string" value="separator"> + <property name="expand" type="bool" value="true"/> + <property name="style" type="uint" value="0"/> + </property> + <property name="plugin-4" type="string" value="pager"/> + <property name="plugin-5" type="string" value="separator"> + <property name="style" type="uint" value="0"/> + </property> + <property name="plugin-6" type="string" value="systray"> + <property name="show-frame" type="bool" value="false"/> + <property name="square-icons" type="bool" value="true"/> + </property> + <property name="plugin-7" type="string" value="statusnotifier"> + <property name="square-icons" type="bool" value="true"/> + <property name="symbolic-icons" type="bool" value="true"/> + </property> + <property name="plugin-8" type="string" value="pulseaudio"> + <property name="enable-keyboard-shortcuts" type="bool" value="true"/> + <property name="show-notifications" type="bool" value="true"/> + </property> + <property name="plugin-9" type="string" value="power-manager-plugin"/> + <property name="plugin-11" type="string" value="separator"> + <property name="style" type="uint" value="0"/> + </property> + <property name="plugin-12" type="string" value="clock"/> + <property name="plugin-13" type="string" value="separator"> + <property name="style" type="uint" value="0"/> + </property> + <property name="plugin-14" type="string" value="actions"> + <property name="items" type="array"> + <value type="string" value="+lock-screen"/> + <value type="string" value="-switch-user"/> + <value type="string" value="-separator"/> + <value type="string" value="-suspend"/> + <value type="string" value="-hibernate"/> + <value type="string" value="-separator"/> + <value type="string" value="-shutdown"/> + <value type="string" value="-restart"/> + <value type="string" value="+separator"/> + <value type="string" value="+logout"/> + <value type="string" value="-logout-dialog"/> + </property> + </property> + <property name="plugin-15" type="string" value="showdesktop"/> + <property name="plugin-16" type="string" value="separator"/> + <property name="plugin-17" type="string" value="launcher"> + <property name="items" type="array"> + <value type="string" value="xfce4-terminal-emulator.desktop"/> + </property> + </property> + <property name="plugin-18" type="string" value="launcher"> + <property name="items" type="array"> + <value type="string" value="xfce4-file-manager.desktop"/> + </property> + </property> + <property name="plugin-19" type="string" value="launcher"> + <property name="items" type="array"> + <value type="string" value="xfce4-web-browser.desktop"/> + </property> + </property> + <property name="plugin-20" type="string" value="launcher"> + <property name="items" type="array"> + <value type="string" value="xfce4-appfinder.desktop"/> + </property> + </property> + <property name="plugin-21" type="string" value="separator"/> + <property name="plugin-22" type="string" value="directorymenu"/> + </property> +</channel> diff --git a/data/root/.bashrc b/data/root/.bashrc new file mode 100644 index 0000000..9302f0d --- /dev/null +++ b/data/root/.bashrc @@ -0,0 +1,110 @@ +# ~/.bashrc: executed by bash(1) for non-login shells. +# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) +# for examples + +# If not running interactively, don't do anything +[ -z "$PS1" ] && return + +# don't put duplicate lines in the history. See bash(1) for more options +# ... or force ignoredups and ignorespace +HISTCONTROL=ignoredups:ignorespace + +# append to the history file, don't overwrite it +shopt -s histappend + +# for setting history length see HISTSIZE and HISTFILESIZE in bash(1) +HISTSIZE=1000 +HISTFILESIZE=2000 + +# check the window size after each command and, if necessary, +# update the values of LINES and COLUMNS. +shopt -s checkwinsize + +# make less more friendly for non-text input files, see lesspipe(1) +[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" + +# set variable identifying the chroot you work in (used in the prompt below) +if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then + debian_chroot=$(cat /etc/debian_chroot) +fi + +# set a fancy prompt (non-color, unless we know we "want" color) +case "$TERM" in + xterm-color) color_prompt=yes;; +esac + +# uncomment for a colored prompt, if the terminal has the capability; turned +# off by default to not distract the user: the focus in a terminal window +# should be on the output of commands, not on the prompt +force_color_prompt=yes + +if [ -n "$force_color_prompt" ]; then + if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then + # We have color support; assume it's compliant with Ecma-48 + # (ISO/IEC-6429). (Lack of such support is extremely rare, and such + # a case would tend to support setf rather than setaf.) + color_prompt=yes + else + color_prompt= + fi +fi + +if [ "$color_prompt" = yes ]; then + PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' +else + PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' +fi +unset color_prompt force_color_prompt + +# If this is an xterm set the title to user@host:dir +case "$TERM" in +xterm*|rxvt*) + PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1" + ;; +*) + ;; +esac + +# enable color support of ls and also add handy aliases +if [ -x /usr/bin/dircolors ]; then + test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" + alias ls='ls --color=auto' + #alias dir='dir --color=auto' + #alias vdir='vdir --color=auto' + + alias grep='grep --color=auto' + alias fgrep='fgrep --color=auto' + alias egrep='egrep --color=auto' +fi + +# some more ls aliases +alias ll='ls -alF' +alias la='ls -A' +alias l='ls -CF' +dmesg() { + if [ -t 1 ]; then + /usr/bin/dmesg --color=always "$@" | less -R + else + /usr/bin/dmesg "$@" + fi +} +steal_x() { + export XAUTHORITY="/run/lightdm/root/:0" + export DISPLAY=:0 +} + +# Alias definitions. +# You may want to put all your additions into a separate file like +# ~/.bash_aliases, instead of adding them here directly. +# See /usr/share/doc/bash-doc/examples in the bash-doc package. + +if [ -f ~/.bash_aliases ]; then + . ~/.bash_aliases +fi + +# enable programmable completion features (you don't need to enable +# this, if it's already enabled in /etc/bash.bashrc and /etc/profile +# sources /etc/bash.bashrc). +if [ -f /etc/bash_completion ] && ! shopt -oq posix; then + . /etc/bash_completion +fi diff --git a/data/usr/lib/x86_64-linux-gnu/libexec/kscreenlocker_greet b/data/usr/lib/x86_64-linux-gnu/libexec/kscreenlocker_greet new file mode 100755 index 0000000..04f388d --- /dev/null +++ b/data/usr/lib/x86_64-linux-gnu/libexec/kscreenlocker_greet @@ -0,0 +1,5 @@ +#!/bin/sh + +xscreensaver-command -lock & +sleep 1 +loginctl unlock-session "$XDG_SESSION_ID" diff --git a/data/usr/share/wallpapers/bwLehrpool/contents/images/1920x1080.png b/data/usr/share/wallpapers/bwLehrpool/contents/images/1920x1080.png Binary files differnew file mode 100644 index 0000000..bcad928 --- /dev/null +++ b/data/usr/share/wallpapers/bwLehrpool/contents/images/1920x1080.png diff --git a/data/usr/share/wallpapers/bwLehrpool/metadata.desktop b/data/usr/share/wallpapers/bwLehrpool/metadata.desktop new file mode 100644 index 0000000..5160b7a --- /dev/null +++ b/data/usr/share/wallpapers/bwLehrpool/metadata.desktop @@ -0,0 +1,7 @@ +[Desktop Entry] +Name=bwLehrpool + +X-KDE-PluginInfo-Name=bwLehrpool +X-KDE-PluginInfo-Author=bwLehrpool +X-KDE-PluginInfo-Email=bwlehrpool@hs-offenburg.de +X-KDE-PluginInfo-License=GPLv2 diff --git a/data/var/lib/locales/supported.d/de b/data/var/lib/locales/supported.d/de new file mode 100644 index 0000000..029a93f --- /dev/null +++ b/data/var/lib/locales/supported.d/de @@ -0,0 +1 @@ +de_DE.UTF-8 UTF-8 diff --git a/data/var/lib/locales/supported.d/en b/data/var/lib/locales/supported.d/en new file mode 100644 index 0000000..230dd52 --- /dev/null +++ b/data/var/lib/locales/supported.d/en @@ -0,0 +1 @@ +en_GB.UTF-8 UTF-8 |