debmaker/ressources/joplin-server/rootfs/DEBIAN/postinst
2025-04-14 18:51:11 +02:00

10 lines
426 B
Bash
Executable file
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/bin/bash
APP=joplin-server
id $APP &> /dev/null || useradd $APP -r -s /bin/false -md /var/lib/$APP/
chown -R $APP:$APP /var/lib/$APP/
## issue https://github.com/laurent22/joplin/issues/5980
[ ! -e /usr/lib/$APP/server/temp/ ] && mkdir /usr/lib/$APP/server/temp/
[ ! -e /usr/lib/$APP/server/logs/ ] && mkdir /usr/lib/$APP/server/logs/
chown $APP:$APP /usr/lib/$APP/server/temp/
chown $APP:$APP /usr/lib/$APP/server/logs/