Package vitastor-common: Scripts

Pre install

groupadd -r -f vitastor 2>/dev/null ||:
useradd  -r -g vitastor -s /sbin/nologin -c "Vitastor daemons" -M -d /var/lib/vitastor vitastor 2>/dev/null ||:

#%post mon
#/usr/sbin/post_service vitastor-mon

#%preun mon
#/usr/sbin/preun_service vitastor-mon

#%post osd
#systemctl daemon-reload ||:
#if [ "$1" -eq 1 ]; then
#        systemctl -q preset vitastor-osd@\*.service vitastor-osd.target ||:
#else
#        systemctl try-restart vitastor-osd.target ||:
#fi

#%preun osd
#if [ "$1" -eq 0 ]; then
#        systemctl --no-reload -q disable vitastor-osd@\*.service vitastor-osd.target ||:
#        systemctl stop vitastor-osd@\*.service  vitastor-osd.target ||:
#fi