chiark / gitweb /
userv-dyndns postinst: move shebang to top of file
[userv-utils.git] / debian / userv-dyndns.postinst
1 #!/bin/sh
2 set -e
3
4 # Copyright 1996-2013 Ian Jackson <ijackson@chiark.greenend.org.uk>
5 # Copyright 1998 David Damerell <damerell@chiark.greenend.org.uk>
6 # Copyright 1999,2003
7 #    Chancellor Masters and Scholars of the University of Cambridge
8 # Copyright 2010 Tony Finch <fanf@dotat.at>
9 #
10 # This is free software; you can redistribute it and/or modify it
11 # under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; either version 3 of the License, or
13 # (at your option) any later version.
14 #
15 # This program is distributed in the hope that it will be useful, but
16 # WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18 # General Public License for more details.
19 #
20 # You should have received a copy of the GNU General Public License
21 # along with userv-utils; if not, see http://www.gnu.org/licenses/.
22
23 #DEBHELPER#
24
25 user="$(sed -n '/^[a-z]/{p;q;}' /etc/userv/dyndns-service-users)"
26
27 if [ "$user" ]; then
28         adduser --system --quiet --group --gecos 'userv dyndns' \
29                 --home /etc/userv --no-create-home --shell /bin/false $user
30 fi