#!/bin/bash set -e case "$1" in configure) if ! id -u blockbook-bch &> /dev/null then useradd --system -M -U blockbook-bch -s /bin/false fi for dir in /opt/coins/data/bch/blockbook /opt/coins/blockbook/bch/logs do if [ "$(stat -c '%U' $dir)" != "blockbook-bch" ] then chown -R blockbook-bch:blockbook-bch $dir fi done ;; esac #DEBHELPER#