#!/bin/bash set -e . /etc/wb_env.sh wb_source "of" CONFFILE=/etc/wb-mqtt-serial.conf if of_machine_match "wirenboard,wirenboard-8xx"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb8" elif of_machine_match "wirenboard,wirenboard-720"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb7" elif of_machine_match "contactless,imx6ul-wirenboard670"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb67" elif of_machine_match "contactless,imx6ul-wirenboard60"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb6" elif of_machine_match "contactless,imx28-wirenboard50"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb5" elif of_machine_match "contactless,imx23-wirenboard41" || of_machine_match "contactless,imx23-wirenboard32" || of_machine_match "contactless,imx23-wirenboard28"; then BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.wb234" else BOARD_CONF="/usr/share/wb-mqtt-serial/wb-mqtt-serial.conf.default" fi ucf --debconf-ok $BOARD_CONF $CONFFILE rm -f /usr/share/wb-mqtt-confed/schemas/wb-mqtt-serial.schema.json # Automatically added by dh_systemd_enable/13.3.4 if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then # This will only remove masks created by d-s-h on package removal. deb-systemd-helper unmask 'wb-mqtt-serial.service' >/dev/null || true # was-enabled defaults to true, so new installations run enable. if deb-systemd-helper --quiet was-enabled 'wb-mqtt-serial.service'; then # Enables the unit on first installation, creates new # symlinks on upgrades if the unit file has changed. deb-systemd-helper enable 'wb-mqtt-serial.service' >/dev/null || true else # Update the statefile to add new symlinks (if any), which need to be # cleaned up on purge. Also remove old symlinks. deb-systemd-helper update-state 'wb-mqtt-serial.service' >/dev/null || true fi fi # End automatically added section # Automatically added by dh_systemd_start/13.3.4 if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort-remove" ] ; then if [ -d /run/systemd/system ]; then systemctl --system daemon-reload >/dev/null || true deb-systemd-invoke start 'wb-mqtt-serial.service' >/dev/null || true fi fi # End automatically added section