File: config

package info (click to toggle)
openvpn 2.0-1sarge4
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 3,392 kB
  • ctags: 4,540
  • sloc: ansic: 42,815; sh: 4,111; makefile: 185; perl: 55
file content (39 lines) | stat: -rw-r--r-- 958 bytes parent folder | download
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
#!/bin/sh
# Copyright 2003 Alberto Gonzalez Iniesta <agi@agi.as>
# Licensed under the GNU General Public License, version 2.  See the file
# /usr/share/common-licenses/GPL or <http://www.gnu.org/copyleft/gpl.txt>.
#
set -e
test $DEBIAN_SCRIPT_DEBUG && set -v -x

# Use debconf
. /usr/share/debconf/confmodule

# Do we want to create /dev/net/tun?
if [ ! -e /dev/net/tun ]; then
  db_input medium openvpn/create_tun || true
  db_go
fi

# if we're upgrading
if [ -n "$2" ] ; then
  # Do we want to move the old S20 symlinks to S18 ones?
  if `dpkg --compare-versions "$2" lt 1.4.3-2`; then
    db_input medium openvpn/change_init || true
    db_go
  fi
  # warn about default port change
  if `dpkg --compare-versions "$2" lt 1.99+2.beta17`; then
    db_input high openvpn/default_port || true
    db_go
  fi
fi

# do we want to stop opevpn while upgrading?
db_input medium openvpn/stop2upgrade || true
db_go

db_stop

exit 0
# vim: set ai et sts=2 sw=2 tw=0: