#!/bin/sh # $Id: init,v 1.3 2004/03/16 01:43:45 zal Exp $ # # Script to remove stale screen named pipes on bootup. # ### BEGIN INIT INFO # Provides: screen-cleanup # Required-Start: $remote_fs # Required-Stop: $remote_fs # Default-Start: S # Default-Stop: # Short-Description: screen sessions cleaning # Description: Cleans up the screen session directory and fixes its # permissions if needed. ### END INIT INFO set -e test -f /usr/bin/screen || exit 0 SCREENDIR=/run/screen case "$1" in start) if test -L $SCREENDIR || ! test -d $SCREENDIR; then rm -f $SCREENDIR mkdir $SCREENDIR chown root:utmp $SCREENDIR [ -x /sbin/restorecon ] && /sbin/restorecon $SCREENDIR fi find $SCREENDIR -type p -delete # If the local admin has used dpkg-statoverride to install the screen # binary with different set[ug]id bits, change the permissions of # $SCREENDIR accordingly BINARYPERM=`stat -c%a /usr/bin/screen` if [ "$BINARYPERM" -ge 4000 ]; then chmod 0755 $SCREENDIR elif [ "$BINARYPERM" -ge 2000 ]; then chmod 0775 $SCREENDIR else chmod 1777 $SCREENDIR fi ;; stop|restart|reload|force-reload) ;; esac exit 0
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
S01apparmor | File | 4.23 KB | 0755 |
|
S01cryptdisks | File | 937 B | 0755 |
|
S01cryptdisks-early | File | 978 B | 0755 |
|
S01ebtables | File | 4.38 KB | 0755 |
|
S01iscsid | File | 1.47 KB | 0755 |
|
S01keyboard-setup.sh | File | 1.44 KB | 0755 |
|
S01kmod | File | 2 KB | 0755 |
|
S01lm-sensors | File | 883 B | 0755 |
|
S01lvm2 | File | 695 B | 0755 |
|
S01netfilter-persistent | File | 1.33 KB | 0755 |
|
S01open-iscsi | File | 2.44 KB | 0755 |
|
S01plymouth-log | File | 752 B | 0755 |
|
S01pppd-dns | File | 612 B | 0755 |
|
S01procps | File | 1.16 KB | 0755 |
|
S01screen-cleanup | File | 1.19 KB | 0755 |
|
S01udev | File | 5.83 KB | 0755 |
|
S01ufw | File | 2.03 KB | 0755 |
|
S01x11-common | File | 2.69 KB | 0755 |
|