[debian-edu-commits] debian-edu/ 05/15: Remove runlevel related code. (Closes: #872151).

Wolfgang Schweer schweer-guest at moszumanska.debian.org
Sun Feb 4 11:37:18 UTC 2018


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 06facb5f4fb04937eb9acd20339a5b797e6b7919
Author: Wolfgang Schweer <wschweer at arcor.de>
Date:   Sun Feb 4 12:12:52 2018 +0100

    Remove runlevel related code. (Closes: #872151).
    
     Adjust share/ltsp/plugins/ltsp-build-client/Debian-custom/032-edu-pkgs
---
 .../ltsp-build-client/Debian-custom/032-edu-pkgs   | 117 +--------------------
 1 file changed, 3 insertions(+), 114 deletions(-)

diff --git a/share/ltsp/plugins/ltsp-build-client/Debian-custom/032-edu-pkgs b/share/ltsp/plugins/ltsp-build-client/Debian-custom/032-edu-pkgs
index fdbfa52..b0b83f6 100644
--- a/share/ltsp/plugins/ltsp-build-client/Debian-custom/032-edu-pkgs
+++ b/share/ltsp/plugins/ltsp-build-client/Debian-custom/032-edu-pkgs
@@ -49,52 +49,6 @@ diverts_insert() {
     ln -s ./new-install.edu $ROOT$file
 }
 
-only_run_on_rclevel() {
-    runlevel=$1 # Use level N to disable on all levels
-    shift
-    for service in $@ ; do
-	info "Making sure init.d/$service only run in runlevel $runlevel"
-	for link in $(cd $ROOT/etc; ls rc[S2345].d/[SK]*$service || true); do
-            # link now look like 'rcS.d/S99foo'
-            set `echo $link|sed "s%rc\(.\).d\/\([SK]\)\(..\)$service%\1 \2 \3%"`
-            lvl=$1
-            action=$2
-            seq=$3
-            if [ "K" = "$action" ] && [ "$runlevel" = "$lvl" ]; then
-		mv $ROOT/etc/$link $ROOT/etc/rc$lvl.d/S$seq$service
-            fi
-            if [ "S" = "$action" ] && [ "$runlevel" != "$lvl" ]; then
-		mv $ROOT/etc/$link $ROOT/etc/rc$lvl.d/K$seq$service
-            fi
-	done
-    done
-}
-
-enable_on_rclevel() {
-    service=$1
-    shift
-    if [ ! -f $ROOT/etc/init.d/$service ] ; then
-        error "Unable to enable service $service, do not exist"
-        return
-    fi
-    info "Making sure init.d/$service run in runlevel $@"
-    for runlevel in $@ ; do
-        rcd=$ROOT/etc/rc$runlevel.d
-        if [ ! -f $rcd/S??$service ] ; then
-            seq=""
-            for link in $(cd $ROOT/etc; ls rc$runlevel.d/K??$service 2>/dev/null || true); do
-                set `echo $link|sed "s%rc\(.\).d\/\([SK]\)\(..\)$service%\1 \2 \3%"`
-                seq=$3
-                mv $rcd/K??$service $rcd/S$seq$service
-            done
-            if [ -z "$seq" ] ; then # No stop link found, create start link
-                # Assume insserv will pick a better sequence number
-                ln -s ../init.d/$service $rcd/S01$service
-            fi
-        fi
-    done
-}
-
 disable_cronjob() {
     for jobname in $@ ; do
         for crondir in /etc/cron.d /etc/cron.daily /etc/cron.hourly \
@@ -257,80 +211,15 @@ finalization_diskless_workstation() {
     # Remove dependencies pulled in by removed packages
     in_target apt-get -y --purge autoremove
 
-    # Needed to get the loopback interface
-    only_run_on_rclevel S ifupdown networking
-
-    # Needed to get utmp (and w/who working)
-    only_run_on_rclevel S bootmisc.sh
-
-    # a lot of services should only be started in runlevel 3, eg, when
-    # running in workstation mode.  Portmap should not start in rcS.d,
-    # to avoid it on thin clients.
-    #enable_on_rclevel portmap 3
-    #enable_on_rclevel nfs-common 3
-    #enable_on_rclevel dbus 3
-    #enable_on_rclevel hal 3
-    #only_run_on_rclevel 3 gdm xdm nscd cupsys autofs pulseaudio \
-    #    rpcbind nfs-common nslcd rwhod saned cups timidity jackd cron \
-    #    speech-dispatcher binfmt-support avahi-daemon bluetooth
-
-    # a lot of services should only be started in runlevel 4, eg. when running
-    # in thin client mode
-    #only_run_on_rclevel 4 ltsp-client samba ltsp-client-core
-
-    # Some services should not be started on the terminals
-    only_run_on_rclevel N enable-nat \
-        cfengine2 xdebian-edu-firstboot \
-        early-readahead later-readahead readahead readahead-desktop \
-        stop-readahead stop-readahead-fedora \
-        exim4 openvpn \
-        resize_lvm hdparm rsync hddtemp fam resolvconf fetch-ldap-cert \
-        firefox-ldapconf
-
-    # check which network the install is on, and start either as
-    # diskless workstation or thin client.  Make sure to insert these
-    # after using only_run_on_rclevel, as the latter do not invoke
-    # update-rc.d to reorder scripts based on dependencies.
-    #if [ ! -h $ROOT/etc/init.d/ltsp_set_runlevel ] ; then
-    #    ln -s /usr/share/debian-edu-config/ltsp_set_runlevel \
-    #        $ROOT/etc/init.d/ltsp_set_runlevel
-    #    in_target update-rc.d ltsp_set_runlevel start 99 S .
-    #fi
-
-    # make cdrom and other static local devices work for diskless
-    # workstation.
-    #if [ ! -h $ROOT/etc/init.d/ltsp_local_mount ] ; then
-    #    ln -sf /usr/share/debian-edu-config/ltsp_local_mount \
-    #        $ROOT/etc/init.d/ltsp_local_mount
-    #    in_target update-rc.d ltsp_local_mount start 01 3 .
-    #fi
-
-
     # Disable the cron jobs that should not be running on a diskless
-    # workstation.  Keep rwhod, shutdown-at-night and
-    # sitesummary-client.
+    # workstation (in addition to LTSP default disabled ones).
+    # Keep rwhod, shutdown-at-night and sitesummary-client.
     disable_cronjob \
-        apt \
-        apt-xapian-index \
-        aptitude \
         bsdmainutils \
-        cvs \
         desktop-profiles \
-        dpkg \
-        etcinsvk \
         etckeeper \
-        exim4-base \
-        htdig \
         killer \
-        logrotate \
-        man-db \
-        mlocate \
-        ntp \
-        popularity-contest \
-        readahead \
-        readahead-monthly \
-        scrollkeeper \
-        standard
+        ntp
 
     # Make sure ifupdown knows about loopback
     cat <<'EOF' | append_if_missing $ROOT/etc/network/interfaces \

-- 
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