diff options
author | Jonathan Bauer | 2020-08-10 15:10:36 +0200 |
---|---|---|
committer | Jonathan Bauer | 2020-08-10 15:10:36 +0200 |
commit | a5a99f8a16abc1413dc9b0d3755e545fb72ad211 (patch) | |
tree | 0ce0c646bc090d9bc4d59f4a36c1c8b33ffc6de9 | |
parent | [dnbd3] fix fuse group creation (diff) | |
parent | [xorg] Conditionally apply Iris workaround (diff) | |
download | mltk-a5a99f8a16abc1413dc9b0d3755e545fb72ad211.tar.gz mltk-a5a99f8a16abc1413dc9b0d3755e545fb72ad211.tar.xz mltk-a5a99f8a16abc1413dc9b0d3755e545fb72ad211.zip |
Merge branch 'master' into installer
5 files changed, 32 insertions, 20 deletions
diff --git a/core/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store b/core/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store index a18b21c7..a9ce62b6 100755 --- a/core/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store +++ b/core/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store @@ -17,15 +17,15 @@ if [ "${SLX_VM_NFS#//}" = "${SLX_VM_NFS}" ]; then # doesn't start with '//' -> assume NFS RET=1 if [ -n "$SLX_VM_NFS_OPTS" ]; then - /opt/openslx/bin/timeout -t 10 -s 9 mount -v -t nfs -o "${SLX_VM_NFS_OPTS},ro" "$SLX_VM_NFS" /mnt/vmstore + /opt/openslx/bin/timeout -s 9 10 mount -v -t nfs -o "${SLX_VM_NFS_OPTS},ro" "$SLX_VM_NFS" /mnt/vmstore RET=$? fi if [ "$RET" != "0" ]; then - /opt/openslx/bin/timeout -t 6 -s 9 mount -v -t nfs -o ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore + /opt/openslx/bin/timeout -s 9 6 mount -v -t nfs -o ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore RET=$? fi if [ "$RET" != "0" ]; then - /opt/openslx/bin/timeout -t 6 -s 9 mount -v -t nfs -o vers=3,ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore + /opt/openslx/bin/timeout -s 9 6 mount -v -t nfs -o vers=3,ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore RET=$? fi else @@ -34,7 +34,7 @@ else export PASSWD="$SLX_VM_NFS_PASSWD" RET=1 if [ -n "$SLX_VM_NFS_OPTS" ]; then - /opt/openslx/bin/timeout -t 10 -s 9 mount -v -t cifs -o "${SLX_VM_NFS_OPTS},uid=0,gid=0,forceuid,forcegid,file_mode=0664,dir_mode=0775,ro" "$SLX_VM_NFS" /mnt/vmstore + /opt/openslx/bin/timeout -s 9 10 mount -v -t cifs -o "${SLX_VM_NFS_OPTS},uid=0,gid=0,forceuid,forcegid,file_mode=0664,dir_mode=0775,ro" "$SLX_VM_NFS" /mnt/vmstore RET=$? fi if [ "$RET" != "0" ]; then @@ -42,7 +42,7 @@ else [ -n "$vers" ] && vers=",vers=${vers}" for sec in "" "ntlmssp" "ntlmv2" "ntlm"; do [ -n "$sec" ] && sec=",sec=${sec}" - /opt/openslx/bin/timeout -t 10 -s 9 mount -v -t cifs -o "ro,file_mode=0644,dir_mode=0755,uid=0,gid=0,forceuid,forcegid,nounix${vers}${sec}" "$SLX_VM_NFS" /mnt/vmstore + /opt/openslx/bin/timeout -s 9 10 mount -v -t cifs -o "ro,file_mode=0644,dir_mode=0755,uid=0,gid=0,forceuid,forcegid,nounix${vers}${sec}" "$SLX_VM_NFS" /mnt/vmstore RET=$? [ "$RET" = "0" ] && break done diff --git a/core/modules/run-virt/data/opt/openslx/scripts/systemd-run_virt_env b/core/modules/run-virt/data/opt/openslx/scripts/systemd-run_virt_env index 4a9aa307..6efcbc23 100755 --- a/core/modules/run-virt/data/opt/openslx/scripts/systemd-run_virt_env +++ b/core/modules/run-virt/data/opt/openslx/scripts/systemd-run_virt_env @@ -194,7 +194,7 @@ getips () { [ -z "$1" ] && return [ "$1" = "$FALLBACK_DOMAIN" ] && return # Output in one line by using echo without quotes - echo $(busybox timeout -t 2 nslookup "$1" 2>/dev/null | grep -A 4 '^Name:' | grep -E '^Address\s*[0-9]*: ' | awk -F': ' '{print $2}' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+' | awk '{print $1}') + echo $(busybox timeout 2 nslookup "$1" 2>/dev/null | grep -A 4 '^Name:' | grep -E '^Address\s*[0-9]*: ' | awk -F': ' '{print $2}' | grep -oE '[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+' | awk '{print $1}') } getresolvconf() { awk -vattr="$1" '$1 == attr {for (i=2; i<=NF; i++) printf "%s ",$i}' /etc/resolv.conf diff --git a/core/modules/systemd-distro/module.conf.ubuntu b/core/modules/systemd-distro/module.conf.ubuntu index 5a90a5a9..3ce18e3a 100644 --- a/core/modules/systemd-distro/module.conf.ubuntu +++ b/core/modules/systemd-distro/module.conf.ubuntu @@ -1,16 +1,4 @@ #!/bin/bash -REQUIRED_INSTALLED_PACKAGES=" - intltool - gperf - dbus - libcap-dev - libudev-dev - libdbus-1-dev - xsltproc - libblkid-dev - libacl1-dev - libpam-dev -" REQUIRED_CONTENT_PACKAGES=" systemd diff --git a/core/modules/xorg/data/etc/X11/Xsession.d/10-fix-vmware-3d b/core/modules/xorg/data/etc/X11/Xsession.d/10-fix-vmware-3d index 05382879..8a436ec1 100644 --- a/core/modules/xorg/data/etc/X11/Xsession.d/10-fix-vmware-3d +++ b/core/modules/xorg/data/etc/X11/Xsession.d/10-fix-vmware-3d @@ -6,5 +6,21 @@ # and newer, which unfortunately completely breaks 3D acceleration with # VMware 15.5.6 (as of 2020-08-04 with Mesa 20.0 + Ubuntu 20.04 as base) -export MESA_LOADER_DRIVER_OVERRIDE=i965 +drivers="$( grep -Po '(?<=Matched )\S*' /var/log/Xorg.0.log )" +intel=false +other=false +for driver in $drivers; do + case "$driver" in + ati|amdgpu|nvidia|nouveau|vmware) + other=true + ;; + intel) + intel=true + ;; + esac +done +if $intel && ! $other; then + export MESA_LOADER_DRIVER_OVERRIDE=i965 +fi +true diff --git a/core/rootfs/rootfs-stage31/data/inc/activate_sysconfig b/core/rootfs/rootfs-stage31/data/inc/activate_sysconfig index 2d6015e1..c93d6e0d 100644 --- a/core/rootfs/rootfs-stage31/data/inc/activate_sysconfig +++ b/core/rootfs/rootfs-stage31/data/inc/activate_sysconfig @@ -65,7 +65,15 @@ install_config_tgz() { local TEMP_EXTRACT_DIR="/tmp/config.tgz.tmp" # TODO perserve existing directories permissions (but overwrite the permissions of files!) mkdir -p "${TEMP_EXTRACT_DIR}" - tar xf "${CONFIG}.tgz" -C "${TEMP_EXTRACT_DIR}" || { echo "Could not untar ${CONFIG}.tgz to ${TEMP_EXTRACT_DIR}"; return 1; } + # Recent versions of busybox tar bail out if two symlinks with the same name exist in archive + if ! tar xf "${CONFIG}.tgz" -C "${TEMP_EXTRACT_DIR}" 2> /tmp/tarpit; then + # Exit code is unclean... + if ! [ -s /tmp/tarpit ] || grep -q -v 'create symlink' /tmp/tarpit; then + # ...and we have en empty error log, OR any error that isn't "can't create symlink" -> abort + echo "Could not untar ${CONFIG}.tgz to ${TEMP_EXTRACT_DIR}" + return 1 + fi + fi # Write list to stage32 for debug tar tvf "${CONFIG}.tgz" > "${FUTURE_ROOT}/opt/openslx/config.tgz.list" 2>&1 chown -R 0:0 "${TEMP_EXTRACT_DIR}" 2>/dev/null |