#!/bin/sh set -e case "$1" in configure) if ( nextcloud-occ status | grep -q 'installed: false' ); then echo 'Nextcloud is not configured. Run:' echo echo ' nextcloud-occ maintenance:install --data-dir=/var/lib/nextcloud/data' echo else nextcloud-occ upgrade fi ;; abort-upgrade|abort-remove|abort-deconfigure) ;; *) echo "postinst called with unknown argument \`$1'" >&2 exit 1 ;; esac #DEBHELPER# exit 0