From e89c3ae528d667a63b9716653f9f926bf416f2ee Mon Sep 17 00:00:00 2001 From: Gabriel Arakaki Giovanini Date: Fri, 10 Mar 2023 21:53:09 +0100 Subject: feat: add initial photoview APKBUILD --- apks/photoview/photoview.initd | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 apks/photoview/photoview.initd (limited to 'apks/photoview/photoview.initd') diff --git a/apks/photoview/photoview.initd b/apks/photoview/photoview.initd new file mode 100644 index 0000000..04a799c --- /dev/null +++ b/apks/photoview/photoview.initd @@ -0,0 +1,40 @@ +#!/sbin/openrc-run +supervisor=supervise-daemon + +command="/usr/bin/photoview" +command_background="yes" +command_user="photoview:photoview" + +# database +export PHOTOVIEW_DATABASE_DRIVER +export PHOTOVIEW_SQLITE_PATH +export PHOTOVIEW_MYSQL_URL +export PHOTOVIEW_POSTGRES_URL + +export PHOTOVIEW_LISTEN_IP +export PHOTOVIEW_LISTEN_PORT +export PHOTOVIEW_SERVE_UI +export PHOTOVIEW_UI_PATH +export PHOTOVIEW_MEDIA_CACHE + +# features +export PHOTOVIEW_DISABLE_FACE_RECOGNITION +export PHOTOVIEW_DISABLE_VIDEO_ENCODING +export PHOTOVIEW_DISABLE_RAW_PROCESSING + +logdir="/var/log/photoview" +error_log="$logdir/${SVCNAME}.log" +pidfile="/var/run/${SVCNAME}.pid" + +depend() { + need net + after firewall +} + +start_pre() { + checkpath -d -o $command_user -m755 $logdir + checkpath -d -o $command_user -m755 /var/cache/photoview/media_cache + checkpath -d -o $command_user -m755 /var/lib/photoview + checkpath -d -o $command_user -m755 /usr/share/webapps/photoview + checkpath -f -o $command_user -m644 $error_log +} -- cgit v1.2.3