mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-20 00:21:35 +00:00
NagTail is like tail(1), but for the nagios status.dat file.
PR: ports/157495 Submitted by: Ryan Steinmetz <rpsfa@rit.edu>
This commit is contained in:
parent
77a2241234
commit
1b4f975f98
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=275066
@ -143,6 +143,7 @@
|
||||
SUBDIR += nagiostat
|
||||
SUBDIR += nagircbot
|
||||
SUBDIR += nagstamon
|
||||
SUBDIR += nagtail
|
||||
SUBDIR += nagvis
|
||||
SUBDIR += nat
|
||||
SUBDIR += nbtscan
|
||||
|
30
net-mgmt/nagtail/Makefile
Normal file
30
net-mgmt/nagtail/Makefile
Normal file
@ -0,0 +1,30 @@
|
||||
# New ports collection makefile for: net-mgmt/nagtail
|
||||
# Date created: 1 June 2011
|
||||
# Whom: Ryan Steinmetz <rpsfa@rit.edu>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= nagtail
|
||||
PORTVERSION= 0.0.31
|
||||
CATEGORIES= net-mgmt
|
||||
MASTER_SITES= http://www.vanheusden.com/nagtail/ \
|
||||
http://people.rit.edu/rpsfa/
|
||||
EXTRACT_SUFX= .tgz
|
||||
|
||||
MAINTAINER= rpsfa@rit.edu
|
||||
COMMENT= Tail for the nagios status.dat file
|
||||
|
||||
USE_GMAKE= yes
|
||||
|
||||
MAN1= nagtail.1
|
||||
MANCOMPRESSED= yes
|
||||
PLIST_FILES= bin/nagtail
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
do-install:
|
||||
@${INSTALL_PROGRAM} ${WRKSRC}/nagtail ${PREFIX}/bin
|
||||
@${INSTALL_MAN} ${WRKSRC}/nagtail.1.gz ${MAN1PREFIX}/man/man1
|
||||
|
||||
.include <bsd.port.post.mk>
|
2
net-mgmt/nagtail/distinfo
Normal file
2
net-mgmt/nagtail/distinfo
Normal file
@ -0,0 +1,2 @@
|
||||
SHA256 (nagtail-0.0.31.tgz) = 8c26bee07a75de77a0c74b3c2ee1dfba59bca1258259748cd92ed364b828f2aa
|
||||
SIZE (nagtail-0.0.31.tgz) = 13995
|
15
net-mgmt/nagtail/files/patch-br.cpp
Normal file
15
net-mgmt/nagtail/files/patch-br.cpp
Normal file
@ -0,0 +1,15 @@
|
||||
--- br.cpp.orig 2011-06-01 07:28:11.000000000 -0400
|
||||
+++ br.cpp 2011-06-01 07:28:49.000000000 -0400
|
||||
@@ -251,10 +251,10 @@
|
||||
return out;
|
||||
}
|
||||
|
||||
-off64_t buffered_reader::file_offset(void)
|
||||
+off_t buffered_reader::file_offset(void)
|
||||
{
|
||||
if (mmap_addr)
|
||||
return cur_offset - mmap_addr;
|
||||
else
|
||||
- return lseek64(fd, 0, SEEK_CUR);
|
||||
+ return lseek(fd, 0, SEEK_CUR);
|
||||
}
|
18
net-mgmt/nagtail/files/patch-br.h
Normal file
18
net-mgmt/nagtail/files/patch-br.h
Normal file
@ -0,0 +1,18 @@
|
||||
--- br.h.orig 2011-06-01 07:45:29.000000000 -0400
|
||||
+++ br.h 2011-06-01 07:45:38.000000000 -0400
|
||||
@@ -33,7 +33,7 @@
|
||||
char *buffer;
|
||||
long long int buffer_length, buffer_pointer;
|
||||
char *mmap_addr, *cur_offset;
|
||||
- off64_t size_of_file;
|
||||
+ off_t size_of_file;
|
||||
|
||||
int number_of_bytes_in_buffer(void);
|
||||
int read_into_buffer(void);
|
||||
@@ -46,5 +46,5 @@
|
||||
|
||||
char * read_line(void);
|
||||
|
||||
- off64_t file_offset(void);
|
||||
+ off_t file_offset(void);
|
||||
};
|
20
net-mgmt/nagtail/files/patch-main.cpp
Normal file
20
net-mgmt/nagtail/files/patch-main.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
--- main.cpp.orig 2011-06-01 07:45:51.000000000 -0400
|
||||
+++ main.cpp 2011-06-01 07:46:28.000000000 -0400
|
||||
@@ -35,7 +35,7 @@
|
||||
struct stats *prev = NULL;
|
||||
int n_prev = 0;
|
||||
int c;
|
||||
- char *statuslog = "/usr/local/nagios/var/status.log";
|
||||
+ char *statuslog = "/var/spool/nagios/status.dat";
|
||||
int check_interval = 60;
|
||||
char verbose = 0;
|
||||
char is_20_format = 1;
|
||||
@@ -110,7 +110,7 @@
|
||||
}
|
||||
|
||||
if (is_file == 1) /* file */
|
||||
- fd = open64(statuslog, O_RDONLY);
|
||||
+ fd = open(statuslog, O_RDONLY);
|
||||
else
|
||||
fd = connect_to(statuslog);
|
||||
|
10
net-mgmt/nagtail/files/patch-utils.cpp
Normal file
10
net-mgmt/nagtail/files/patch-utils.cpp
Normal file
@ -0,0 +1,10 @@
|
||||
--- utils.cpp.orig 2011-06-01 07:30:26.000000000 -0400
|
||||
+++ utils.cpp 2011-06-01 07:30:35.000000000 -0400
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <netdb.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
+#include <netinet/in.h>
|
||||
extern "C" {
|
||||
#include "error.h"
|
||||
}
|
3
net-mgmt/nagtail/pkg-descr
Normal file
3
net-mgmt/nagtail/pkg-descr
Normal file
@ -0,0 +1,3 @@
|
||||
NagTail is like tail(1), but for the nagios status.dat file.
|
||||
|
||||
WWW: http://www.vanheusden.com/nagtail/
|
Loading…
Reference in New Issue
Block a user