#!/bin/sh set -e case "$1" in configure) # apply bugfix on 2.6 ngcp systems with broken db rev script # /usr/share/ngcp-db-schema/db_scripts/diff/9868.up # ngcp 2.5 repos provides ngcp-db-schema := 0.1.3 # ngcp 2.6 repos provides ngcp-db-schema >= 2.6.3 if [ -n "$2" ] && dpkg --compare-versions $2 gt 0.1.3 && dpkg --compare-versions $2 le 2.6.3 ; then echo "Executing ngcp-update-db-schema to address 2.6 db rev script bug." ngcp-update-db-schema fi ;; abort-upgrade|abort-remove|abort-deconfigure) ;; *) echo "postinst of ngcp-db-schema called with unknown argument \`$1'" >&2 exit 1 ;; esac exit 0