[debian-edu-commits] debian-edu/ 01/01: Add file Debian-custom/001-ltsp-settings. This fixes LTSP chroot installation in case that ltsp-client-builder doesn't look up another mirror if cdrom is still mounted.

Wolfgang Schweer schweer-guest at moszumanska.debian.org
Wed Apr 27 12:47:17 UTC 2016


This is an automated email from the git hooks/post-receive script.

schweer-guest pushed a commit to branch master
in repository debian-edu-config.

commit 7b272eda99d4de57481f062240c64977ba541a34
Author: Wolfgang Schweer <wschweer at arcor.de>
Date:   Wed Apr 27 14:48:42 2016 +0200

    Add file Debian-custom/001-ltsp-settings. This fixes LTSP chroot installation in case that ltsp-client-builder doesn't look up another mirror if cdrom is still mounted.
---
 Makefile                                             |  1 +
 debian/changelog                                     |  3 +++
 .../Debian-custom/001-ltsp-settings                  | 20 ++++++++++++++++++++
 3 files changed, 24 insertions(+)

diff --git a/Makefile b/Makefile
index 89af64b..7896d52 100644
--- a/Makefile
+++ b/Makefile
@@ -432,6 +432,7 @@ install: install-testsuite
 	set -e ; for f in \
  share/ltsp/plugins/ltsp-build-client/Debian-custom/000-arch-detection \
  share/ltsp/plugins/ltsp-build-client/Debian-custom/000-default-dist \
+ share/ltsp/plugins/ltsp-build-client/Debian-custom/001-ltsp-settings \
  share/ltsp/plugins/ltsp-build-client/Debian-custom/002-default-apt-keyring \
  share/ltsp/plugins/ltsp-build-client/Debian-custom/010-set-resolver \
  share/ltsp/plugins/ltsp-build-client/Debian-custom/011-http-nopipeline \
diff --git a/debian/changelog b/debian/changelog
index 6013bc5..1070bf5 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -32,6 +32,9 @@ debian-edu-config (1.901) UNRELEASED; urgency=medium
     - update Makefile.
   * Adjust sbin/debian-edu-pxeinstall to use NBD for LTSP clients; this
     is now the LTSP default, usage of NFS is broken atm (see #786925).
+  * Add file Debian-custom/001-ltsp-settings. This fixes LTSP chroot
+    installation in case that ltsp-client-builder doesn't look up another
+    mirror if cdrom is still mounted.
 
  -- Wolfgang Schweer <wschweer at arcor.de>  Thu, 14 Apr 2016 23:32:10 +0200
 
diff --git a/share/ltsp/plugins/ltsp-build-client/Debian-custom/001-ltsp-settings b/share/ltsp/plugins/ltsp-build-client/Debian-custom/001-ltsp-settings
new file mode 100644
index 0000000..58625e3
--- /dev/null
+++ b/share/ltsp/plugins/ltsp-build-client/Debian-custom/001-ltsp-settings
@@ -0,0 +1,20 @@
+# File Debian-custom/001-ltsp-settings
+# Deal with case that ltsp-client-builder doesn't look up another
+# mirror if cdrom is still mounted.
+case $MODE in
+  configure)
+    if [ file:///media/cdrom = "$option_mirror_value" ] ; then
+        NEWMIRROR=$(awk '/^deb (http|ftp):\/\/.* main/ { if (!first) { print $2; first=1 } }' < /etc/apt/sources.list)
+        echo "info: Changing LTSP mirror from '$option_mirror_value' to '$NEWMIRROR'"
+        option_mirror_value=$NEWMIRROR
+    fi
+  ;;
+  install)
+    mkdir -p $ROOT/etc/apt/apt.conf.d
+    (
+        echo 'APT::Get::AllowUnauthenticated "true";'
+        echo 'APT::Authentication::TrustCDROM "true";'
+        echo 'APT::Cmdline::ignore-trust-violations "true";'
+    ) >> $ROOT/etc/apt/apt.conf.d/90ltsp-build-client
+  ;;
+esac

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-edu/debian-edu-config.git



More information about the debian-edu-commits mailing list