FreeBSD Bugzilla – Attachment 212880 Details for
Bug 245195
sysutils/checkrestart: update to 0.5.0
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to 0.5.0
sysutils-checkrestart-0.5.0.patch (text/plain), 4.76 KB, created by
Thomas Hurst
on 2020-03-31 03:41:02 UTC
(
hide
)
Description:
Patch to 0.5.0
Filename:
MIME Type:
Creator:
Thomas Hurst
Created:
2020-03-31 03:41:02 UTC
Size:
4.76 KB
patch
obsolete
>Index: sysutils/checkrestart/Makefile >=================================================================== >--- sysutils/checkrestart/Makefile (revision 529945) >+++ sysutils/checkrestart/Makefile (working copy) >@@ -2,7 +2,7 @@ > > PORTNAME= checkrestart > DISTVERSIONPREFIX= v >-DISTVERSION= 0.4.0 >+DISTVERSION= 0.5.0 > CATEGORIES= sysutils > > MAINTAINER= tom@hur.st >@@ -14,11 +14,18 @@ > USE_GITHUB= yes > GH_ACCOUNT= Freaky > >+SUB_FILES= checkrestart >+ > PLIST_FILES= bin/checkrestart \ >- share/man/man1/checkrestart.1.gz >+ share/man/man1/checkrestart.1.gz \ >+ etc/periodic/daily/checkrestart > >+PERIODIC_DAILY= etc/periodic/daily >+ > do-install: > ${INSTALL_PROGRAM} ${WRKSRC}/checkrestart ${STAGEDIR}${PREFIX}/bin > ${INSTALL_MAN} ${WRKSRC}/checkrestart.1 ${STAGEDIR}${MAN1PREFIX}/share/man/man1 >+ @${MKDIR} ${STAGEDIR}${PREFIX}/${PERIODIC_DAILY} >+ ${INSTALL_SCRIPT} ${WRKDIR}/checkrestart ${STAGEDIR}${PREFIX}/${PERIODIC_DAILY} > > .include <bsd.port.mk> >Index: sysutils/checkrestart/distinfo >=================================================================== >--- sysutils/checkrestart/distinfo (revision 529945) >+++ sysutils/checkrestart/distinfo (working copy) >@@ -1,3 +1,3 @@ >-TIMESTAMP = 1584926860 >-SHA256 (Freaky-checkrestart-v0.4.0_GH0.tar.gz) = 9c578b7f0c881a10bea040da2c8525c2132bb47f1d85ca05ba6f6a9c6e61b1b4 >-SIZE (Freaky-checkrestart-v0.4.0_GH0.tar.gz) = 5306 >+TIMESTAMP = 1585601339 >+SHA256 (Freaky-checkrestart-v0.5.0_GH0.tar.gz) = c37f40ad618d978fe413c71c367af5aefaeb1d600d72725294df8b3523e20e9c >+SIZE (Freaky-checkrestart-v0.5.0_GH0.tar.gz) = 5659 >Index: sysutils/checkrestart/files/checkrestart.in >=================================================================== >--- sysutils/checkrestart/files/checkrestart.in (nonexistent) >+++ sysutils/checkrestart/files/checkrestart.in (working copy) >@@ -0,0 +1,69 @@ >+#!/bin/sh >+ >+if [ -r /etc/defaults/periodic.conf ]; then >+ . /etc/defaults/periodic.conf >+ source_periodic_confs >+fi >+ >+: "${daily_checkrestart_enable:=NO}" >+: "${daily_checkrestart_weekdays:=1234567}" # Days of the week to run, Monday=1 >+: "${daily_checkrestart_users:=}" # User names or IDs to check >+: "${daily_checkrestart_jails:=}" # Jail names or IDs to check >+: "${daily_checkrestart_procs:=}" # Process names or IDs to check >+ >+checkrestartcmd=/usr/local/bin/checkrestart >+hflag="" >+rc=0 >+ >+export COLUMNS=80 >+ >+checkrestart() { >+ local result >+ result="$(${checkrestartcmd} ${hflag} "$@" -- ${daily_checkrestart_procs} 2>&1)" >+ if [ "$result" ]; then >+ echo "${result}" >+ rc=3 >+ fi >+ hflag="-H" >+} >+ >+checkrestart_each_user() { >+ if [ -n "${daily_checkrestart_users}" ]; then >+ for user in ${daily_checkrestart_users}; do >+ checkrestart -u "${user}" "$@" >+ done >+ else >+ checkrestart "$@" >+ fi >+} >+ >+checkrestart_start() { >+ if [ -n "${daily_checkrestart_jails}" ]; then >+ for jail in ${daily_checkrestart_jails}; do >+ checkrestart_each_user -j "${jail}" >+ done >+ else >+ checkrestart_each_user >+ fi >+} >+ >+checkday() { >+ if echo "${daily_checkrestart_weekdays}" | grep -vq '^[1-7, ]*$'; then >+ echo "daily_checkrestart_weekdays must have values 1-7" >+ exit 2 >+ fi >+ >+ echo "${daily_checkrestart_weekdays}" | grep -Fq "$(date +%u)" >+} >+ >+case "${daily_checkrestart_enable}" in >+ [Yy][Ee][Ss]) >+ if checkday; then >+ echo >+ echo 'Checking for stale processes:' >+ checkrestart_start >+ fi >+ ;; >+esac >+ >+exit $rc > >Property changes on: sysutils/checkrestart/files/checkrestart.in >___________________________________________________________________ >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: sysutils/checkrestart/pkg-message >=================================================================== >--- sysutils/checkrestart/pkg-message (nonexistent) >+++ sysutils/checkrestart/pkg-message (working copy) >@@ -0,0 +1,16 @@ >+[ >+{ type: install, >+ message: <<EOM >+In order to enable periodic(8) checks, set the following in /etc/periodic.conf >+ >+# Required >+daily_checkrestart_enable="YES" >+ >+# Optional >+daily_checkrestart_weekdays="1 4" # only run on Monday and Thursday >+daily_checkrestart_jails="0 web" # limit to jails 0 and web >+daily_checkrestart_users="root www" # limit to root and www users >+daily_checkrestart_procs="smbd httpd" # limit to samba and httpd >+EOM >+} >+] > >Property changes on: sysutils/checkrestart/pkg-message >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
tom
:
maintainer-approval+
Actions:
View
|
Diff
Attachments on
bug 245195
: 212880