diff --git a/www/tinyauth/Makefile b/www/tinyauth/Makefile index e285eb2ad26e..d1121f100870 100644 --- a/www/tinyauth/Makefile +++ b/www/tinyauth/Makefile @@ -1,62 +1,64 @@ PORTNAME= tinyauth DISTVERSIONPREFIX= v -DISTVERSION= 5.0.7 -PORTREVISION= 3 +DISTVERSION= 5.1.2 CATEGORIES= www MASTER_SITES= LOCAL/dtxdf/${PORTNAME}/:assets # For instructions on how to create assets: # https://github.com/DtxdF/port-assets-makejails/tree/main/tinyauth DISTFILES= ${PORTNAME}-${DISTVERSIONPREFIX}${DISTVERSION}.frontend${EXTRACT_SUFX}:assets \ ${PORTNAME}-${DISTVERSIONPREFIX}${DISTVERSION}.vendor${EXTRACT_SUFX}:assets MAINTAINER= dtxdf@FreeBSD.org COMMENT= Simplest way to protect your apps with a login screen WWW= https://tinyauth.app LICENSE= GPLv3 LICENSE_FILE= ${WRKSRC}/LICENSE ONLY_FOR_ARCHS= aarch64 amd64 ONLY_FOR_ARCHS_REASON= module modernc.org/sqlite only supported on aarch64 and amd64 USES= go:1.26+,modules USE_GITHUB= yes GH_ACCOUNT= steveiliop56 USE_RC_SUBR= ${PORTNAME} GO_MOD_DIST= github GO_TARGET= ./cmd/${PORTNAME} GO_BUILDFLAGS= -ldflags "\ -X 'tinyauth/internal/constants.Version=${DISTVERSIONPREFIX}${DISTVERSION}' \ -X 'tinyauth/internal/constants.CommitHash=${GITID}' \ -X 'tinyauth/internal/constants.BuildTimestamp=${BUILD_DATE}'" SUB_FILES= pkg-message SUB_LIST= USER=${USERS:[1]} USERS= ${TINYAUTH_USER} GROUPS= ${TINYAUTH_GROUP} PLIST_FILES= bin/${PORTNAME} \ - "@dir(${TINYAUTH_USER},${TINYAUTH_GROUP},0750) /var/db/${PORTNAME}" + "@dir(${TINYAUTH_USER},${TINYAUTH_GROUP},0750) /var/db/${PORTNAME}" \ + "@sample etc/newsyslog.conf.d/${PORTNAME}.conf.sample" # Run 'git checkout ${DISTVERSIONPREFIX}${DISTVERSION} && git rev-parse HEAD' # in the Tinyauth repository to get the value of GITID. -GITID= 479f1657812b7bf01438607464dedaa148155301 +GITID= c7077a7c845dc71f9cbab55dc15151920887881e BUILD_DATE= $$(date -u '+%Y-%m-%dT%H:%M:%S') TINYAUTH_USER= ${PORTNAME} TINYAUTH_GROUP= ${TINYAUTH_USER} post-extract: @${MKDIR} ${WRKSRC}/vendor @cd ${WRKDIR}/${PORTNAME}-vendor && ${COPYTREE_SHARE} . ${WRKSRC}/vendor @${MKDIR} ${WRKSRC}/internal/assets/dist @cd ${WRKDIR}/${PORTNAME}-frontend && ${COPYTREE_SHARE} . ${WRKSRC}/internal/assets/dist post-install: @${MKDIR} ${STAGEDIR}/var/db/${PORTNAME} + @${MKDIR} ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d + ${INSTALL_DATA} ${FILESDIR}/newsyslog.conf ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d/${PORTNAME}.conf.sample .include diff --git a/www/tinyauth/distinfo b/www/tinyauth/distinfo index f44ac63d1205..e6dc0b89fffc 100644 --- a/www/tinyauth/distinfo +++ b/www/tinyauth/distinfo @@ -1,7 +1,7 @@ -TIMESTAMP = 1776447798 -SHA256 (tinyauth-v5.0.7.frontend.tar.gz) = 0094e98a41f9936416a92b36f86a32a55ea274bd1c78719727ed238ddbdd5546 -SIZE (tinyauth-v5.0.7.frontend.tar.gz) = 988230 -SHA256 (tinyauth-v5.0.7.vendor.tar.gz) = f79834df38daa8cfdd5d9c78fe564846a6b262fc8af7e33e1edd309cb8eefcdc -SIZE (tinyauth-v5.0.7.vendor.tar.gz) = 58190053 -SHA256 (steveiliop56-tinyauth-v5.0.7_GH0.tar.gz) = a1e76e26b964d1888ac7c07b95e3c9adba18840de066fc11a363207d28809611 -SIZE (steveiliop56-tinyauth-v5.0.7_GH0.tar.gz) = 4789501 +TIMESTAMP = 1785101963 +SHA256 (tinyauth-v5.1.2.frontend.tar.gz) = 3e92b322f85f9db0e83c0e0154aa5e4595af36e8902df21a531de6cfdee1dfce +SIZE (tinyauth-v5.1.2.frontend.tar.gz) = 1004510 +SHA256 (tinyauth-v5.1.2.vendor.tar.gz) = b72ad659f124d527ae7e12f454817bc07556ce1ce52f3f4985a1ab1d2d973e53 +SIZE (tinyauth-v5.1.2.vendor.tar.gz) = 39593562 +SHA256 (steveiliop56-tinyauth-v5.1.2_GH0.tar.gz) = 4753242daf3ef02368c3e5c3536a6cb293cf09508c3efcf090fee6ebc4fd403a +SIZE (steveiliop56-tinyauth-v5.1.2_GH0.tar.gz) = 4945950 diff --git a/www/tinyauth/files/newsyslog.conf b/www/tinyauth/files/newsyslog.conf new file mode 100644 index 000000000000..7723d7cfce8e --- /dev/null +++ b/www/tinyauth/files/newsyslog.conf @@ -0,0 +1,6 @@ +# configuration file for newsyslog for tinyauth +# +# see newsyslog.conf(5) for details +# +# logfilename [owner:group] mode count size when flags [/pid_file] [sig_num] +/var/log/tinyauth.log 644 7 1000 * JC /var/run/tinyauthd.pid diff --git a/www/tinyauth/files/tinyauth.in b/www/tinyauth/files/tinyauth.in index 35d0d05f8687..287061014968 100644 --- a/www/tinyauth/files/tinyauth.in +++ b/www/tinyauth/files/tinyauth.in @@ -1,39 +1,40 @@ #!/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_supervisor_pidfile:="/var/run/tinyauthd.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}'" +command_args="-o '${tinyauth_logfile}' -P '${tinyauth_supervisor_pidfile}' -p '${pidfile}' -u '${tinyauth_runas}' -t '${name}: ${desc}' -- '${procname}'" run_rc_command "$1"