Files
ports/www/tinyauth/files/tinyauth.in
T
Jesús Daniel Colmenares Oviedo 86be9c1e21 www/tinyauth: Update to 5.0.4
* Cache vendor stuff.
* Add GO_TARGET.
* Extract frontend and vendor in post-extract instead of pre-build.
* Improve pkg-message to deploy a quick demo.
* Add pkg-message about breaking-changes starting with version 5.0.0.
* Add tinyauth_chdir parameter in rc(8) script.
* Improve format of help options in rc(8) script.

ChangeLog:
https://github.com/steveiliop56/tinyauth/compare/v4.0.1...v5.0.4

Reported by:    ronald@klop.ws (email)
2026-03-27 01:38:48 -04:00

40 lines
1.4 KiB
Bash

#!/bin/sh
# PROVIDE: tinyauth
# REQUIRE: LOGIN
# KEYWORD: shutdown
#
# Configuration settings for tinyauth in /etc/rc.conf
#
# tinyauth_enable (bool): Enable tinyauth. (default=NO)
# tinyauth_chdir (str) Run tinyauth in this directory. (default=/var/db/tinyauth)
# tinyauth_env_file (str): Path containing the environment variables to be used by tinyauth.
# (default=%%PREFIX%%/etc/tinyauth.env)
# tinyauth_logfile (str): Log file used to store the tinyauth's output.
# (default=/var/log/tinyauth.log)
# tinyauth_pidfile (str): File used by tinyauth to store the process ID.
# (default=/var/run/tinyauth.pid)
# tinyauth_runas (str): User to run tinyauth as. (default=%%USER%%)
. /etc/rc.subr
name="tinyauth"
desc="Simplest way to protect your apps with a login screen"
rcvar="tinyauth_enable"
load_rc_config $name
: ${tinyauth_enable:="NO"}
: ${tinyauth_chdir:="/var/db/tinyauth"}
: ${tinyauth_env_file:="%%PREFIX%%/etc/tinyauth.env"}
: ${tinyauth_logfile:="/var/log/tinyauth.log"}
: ${tinyauth_pidfile:="/var/run/tinyauth.pid"}
: ${tinyauth_runas:="%%USER%%"}
pidfile="${tinyauth_pidfile}"
procname="%%LOCALBASE%%/bin/tinyauth"
command="/usr/sbin/daemon"
command_args="-o '${tinyauth_logfile}' -p '${pidfile}' -u '${tinyauth_runas}' -t '${desc}' -- '${procname}'"
run_rc_command "$1"