[go: up one dir, main page]

File: postinst.sh

package info (click to toggle)
qtsmbstatus 2.2.1-3
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 1,368 kB
  • ctags: 567
  • sloc: cpp: 4,333; sh: 171; makefile: 16
file content (41 lines) | stat: -rwxr-xr-x 933 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/bin/bash

# Install System-V style init script links
# Start service

ROOT_DIR=$1

chmod 640 $ROOT_DIR/etc/qtsmbstatusd/*
chmod 750 $ROOT_DIR/etc/init.d/qtsmbstatusd

# service

echo "install System-V style init script links"

if test -s $ROOT_DIR/etc/debian_version; then
	# Debian systems
	echo "Debian systems"
	update-rc.d -f qtsmbstatusd remove 2>/dev/null
	update-rc.d qtsmbstatusd defaults
elif test -s $ROOT_DIR/etc/SuSE-release; then
	# SuSE systems
	echo "SuSE systems"
	insserv -r qtsmbstatusd 2>/dev/null
	insserv qtsmbstatusd
else
	# RedHat systems
	echo "RedHat systems"
	/sbin/chkconfig --del qtsmbstatusd 2>/dev/null
	/sbin/chkconfig --add qtsmbstatusd
fi

# start service
echo "start qtsmbstatusd service"
$ROOT_DIR/etc/init.d/qtsmbstatusd start

echo "Done."
echo
echo "WARNING:"
echo "    PAM configuration file (/etc/pam.d/qtsmbstatusd) is distribution dependent."
echo "    Please read the README file."
echo