#!/bin/sh -e
case "$1" in
	configure)
		# Create the osmocom group and user (if it doesn't exist yet)
		if ! getent group osmocom >/dev/null; then
			groupadd --system osmocom
		fi
		if ! getent passwd osmocom >/dev/null; then
			useradd \
				--system \
				--gid osmocom \
				--home-dir /var/lib/osmocom \
				--shell /sbin/nologin \
				--comment "Open Source Mobile Communications" \
				osmocom
		fi
		;;
esac

# dh_installdeb(1) will replace this with shell code automatically
# generated by other debhelper scripts.
#DEBHELPER#
