From 17a237d5e3738d22aedf95522cb5ecff744586ac Mon Sep 17 00:00:00 2001 From: /jedi/ Date: Mon, 19 Jun 2017 21:43:04 +0200 Subject: [PATCH] debian --- debian/patches/series | 0 debian/postinst | 30 ++++++++++++++++++++++++++++++ debian/tinc.default | 7 +++++++ debian/tinc.dirs | 7 +++++++ debian/tinc.files | 7 +++++++ 5 files changed, 51 insertions(+) create mode 100644 debian/patches/series create mode 100644 debian/postinst create mode 100644 debian/tinc.default create mode 100644 debian/tinc.dirs create mode 100644 debian/tinc.files diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 00000000..e69de29b diff --git a/debian/postinst b/debian/postinst new file mode 100644 index 00000000..c6769fa5 --- /dev/null +++ b/debian/postinst @@ -0,0 +1,30 @@ +#! /bin/sh + +NETSFILE="/etc/tinc/nets.boot" + +set -e + +case "$1" in + configure) + if [ ! -e /dev/.devfsd ] ; then if [ ! -e /dev/.devfs ] ; then + if [ ! -e /dev/net/tun ] ; then if [ ! -e /dev/tun ] ; then if [ -e /dev/MAKEDEV ]; then + echo "Creating tun device..." + cd /dev && ./MAKEDEV net/tun 2>/dev/null || ./MAKEDEV tun 2>/dev/null || echo "Failed to create tun device." + fi; fi; fi + fi; fi + + if [ ! -e $NETSFILE ] ; then + echo "## This file contains all names of the networks to be started on system startup." > $NETSFILE + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 0 + ;; +esac + +#DEBHELPER# diff --git a/debian/tinc.default b/debian/tinc.default new file mode 100644 index 00000000..bca24321 --- /dev/null +++ b/debian/tinc.default @@ -0,0 +1,7 @@ +# Extra options to be passed to tincd. +# EXTRA="-d" + +# Limits to be configured for the tincd process. Please read your shell +# (pointed by /bin/sh) documentation for ulimit. You probably want to raise the +# max locked memory value if using both --mlock and --user flags. +# LIMITS="-l 1024" diff --git a/debian/tinc.dirs b/debian/tinc.dirs new file mode 100644 index 00000000..1eae2e2d --- /dev/null +++ b/debian/tinc.dirs @@ -0,0 +1,7 @@ +usr/sbin +usr/share +etc +etc/init.d +usr/share/locale +usr/share/doc/tinc +etc/tinc diff --git a/debian/tinc.files b/debian/tinc.files new file mode 100644 index 00000000..ed7bd233 --- /dev/null +++ b/debian/tinc.files @@ -0,0 +1,7 @@ +usr/sbin/tincd +usr/sbin/tinc +usr/share/man +etc +usr/share/doc/tinc +usr/share/locale +usr/share/info