Files
qt-migration-legatus/qt6-after/qt6-migrated-legatus/packaging/deb/legatus-qt6-sv/DEBIAN/postinst
T

25 lines
557 B
Bash

#!/bin/sh
set -e
# postinst script for legatus-qt6-sv
if [ "$1" = "configure" ]; then
# Update linker cache
ldconfig
# Create log directory if it doesn't exist
LOGDIR="/opt/legatus/sv/../LOG"
if [ ! -e "${LOGDIR}" ]; then
mkdir -p "${LOGDIR}"
chown root:root "${LOGDIR}"
chmod 1777 "${LOGDIR}"
fi
# Enable systemd service if it exists
if [ -f "/etc/systemd/system/lts_sv.service" ]; then
systemctl daemon-reload
systemctl enable lts_sv.service 2>/dev/null || true
fi
fi
exit 0