* [gentoo-commits] proj/fifo-cronolog:master commit in: /
@ 2024-03-12 18:14 Robin H. Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Robin H. Johnson @ 2024-03-12 18:14 UTC (permalink / raw
To: gentoo-commits
commit: 81713dc3efcbec5ae3006580a97aef519bfc7c2b
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 12 18:06:26 2024 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Mar 12 18:06:26 2024 +0000
URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=81713dc3
fix: bump version to ship docs
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
fifo-cronolog.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fifo-cronolog.c b/fifo-cronolog.c
index f7ff19f..c2875d6 100644
--- a/fifo-cronolog.c
+++ b/fifo-cronolog.c
@@ -14,7 +14,7 @@ SPDX-License-Identifier: BSD-2-Clause
#include <errno.h>
#include <string.h>
-#define VERSION "1.2.0"
+#define VERSION "1.2.1"
char *pidfile;
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [gentoo-commits] proj/fifo-cronolog:master commit in: /
@ 2024-03-12 18:14 Robin H. Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Robin H. Johnson @ 2024-03-12 18:14 UTC (permalink / raw
To: gentoo-commits
commit: a88407d7924b0f45947807981cc8d3327d2c56d4
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 12 18:14:15 2024 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Mar 12 18:14:15 2024 +0000
URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=a88407d7
build: add simple install target
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
Makefile | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/Makefile b/Makefile
index 3baecf8..7894e74 100644
--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,13 @@
CFLAGS += -Wall
BIN = fifo-cronolog
+HELPER = fifo-cronolog-setup
SRC = $(BIN).c
OBJ = $(patsubst %.c,%.o,$(SRC))
+BINDIR = /usr/sbin/
+SYSTEMD_TARGET = /usr/lib/systemd/system/
+SYSTEMD_UNIT = systemd/fifo-cronolog@.service
+
all: $(BIN)
$(BIN): $(OBJ)
@@ -14,4 +19,9 @@ $(BIN): $(OBJ)
clean:
$(RM) $(BIN) $(OBJ)
+install:
+ mkdir -p $(DESTDIR)$(BINDIR) $(DESTDIR)$(SYSTEMD_TARGET)
+ install -m0755 -D $(BIN) $(HELPER) $(DESTDIR)$(BINDIR)
+ install -m0644 -D $(SYSTEMD_UNIT) $(DESTDIR)$(SYSTEMD_TARGET)
+
# vim: set ts=4 sw=4 tw=80:
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [gentoo-commits] proj/fifo-cronolog:master commit in: /
@ 2024-03-12 18:14 Robin H. Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Robin H. Johnson @ 2024-03-12 18:14 UTC (permalink / raw
To: gentoo-commits
commit: 09b3b06ecff704b6b001d6398f506dce9456301f
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 12 18:05:24 2024 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Mar 12 18:05:24 2024 +0000
URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=09b3b06e
build: cleanup Makefile
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
Makefile | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/Makefile b/Makefile
index cca4e8b..3baecf8 100644
--- a/Makefile
+++ b/Makefile
@@ -1,14 +1,17 @@
CFLAGS += -Wall
+BIN = fifo-cronolog
+SRC = $(BIN).c
+OBJ = $(patsubst %.c,%.o,$(SRC))
-all: fifo-cronolog
+all: $(BIN)
-fifo-cronolog: fifo-cronolog.o
+$(BIN): $(OBJ)
$(CC) $(LDFLAGS) -o $@ $<
-fifo-cronolog.o: fifo-cronolog.c
+.c.o:
$(CC) $(CFLAGS) -c -o $@ $<
clean:
- $(RM) fifo-cronolog{,.o}
+ $(RM) $(BIN) $(OBJ)
# vim: set ts=4 sw=4 tw=80:
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [gentoo-commits] proj/fifo-cronolog:master commit in: /
@ 2024-03-12 18:14 Robin H. Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Robin H. Johnson @ 2024-03-12 18:14 UTC (permalink / raw
To: gentoo-commits
commit: 33db6ad55a866b9944d8038e036c7dce65e26eea
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Tue Mar 12 18:05:47 2024 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Tue Mar 12 18:05:47 2024 +0000
URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=33db6ad5
doc: add README & AUTHORS
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
AUTHORS | 2 ++
README.md | 22 ++++++++++++++++++++++
2 files changed, 24 insertions(+)
diff --git a/AUTHORS b/AUTHORS
new file mode 100644
index 0000000..2ca8fed
--- /dev/null
+++ b/AUTHORS
@@ -0,0 +1,2 @@
+Christian Ruppert <idl0r@gentoo.org>
+Robin H. Johnson <robbat2@gentoo.org>
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..7ec95e7
--- /dev/null
+++ b/README.md
@@ -0,0 +1,22 @@
+fifo-cronolog
+-------------
+This is a little tool that connects a named pipe/FIFO into the stdin of `cronolog`.
+
+This is useful for cases where the logging destination cannot be specified as a
+program. It was originally written to do logging from Squid, but later re-used
+for Nginx & other tools.
+
+Cronolog's canonical example, in an Apache configuration
+```
+TransferLog "|/www/sbin/cronolog /www/logs/%Y/%m/%d/access.log"
+```
+
+Is converted into:
+1. Fifo-cronolog as (via your init system, so it gets restarted):
+```
+fifo-cronolog /run/apache-access.pid /run/apache-access.fifo /www/logs/%Y/%m/%d/access.log
+```
+2. Apache configuration:
+```
+TransferLog "/run/apache-access.fifo"
+```
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [gentoo-commits] proj/fifo-cronolog:master commit in: /
@ 2024-03-13 4:52 Robin H. Johnson
0 siblings, 0 replies; 5+ messages in thread
From: Robin H. Johnson @ 2024-03-13 4:52 UTC (permalink / raw
To: gentoo-commits
commit: 80ac76208eade31ad0df6b347481049c20608a39
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
AuthorDate: Wed Mar 13 04:51:37 2024 +0000
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org>
CommitDate: Wed Mar 13 04:51:37 2024 +0000
URL: https://gitweb.gentoo.org/proj/fifo-cronolog.git/commit/?id=80ac7620
build: add hacky dist rule
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org>
.gitignore | 4 +++-
Makefile | 8 ++++++++
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/.gitignore b/.gitignore
index 29b8ac9..718dc26 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,5 @@
-
*.o
fifo-cronolog
+*.tgz
+*.tar.gz
+*.tar
diff --git a/Makefile b/Makefile
index 7894e74..74c132a 100644
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,14 @@ BINDIR = /usr/sbin/
SYSTEMD_TARGET = /usr/lib/systemd/system/
SYSTEMD_UNIT = systemd/fifo-cronolog@.service
+VERSION = $(shell awk -F'"' '/#define VERSION/{print $$2}' $(SRC) )
+DISTFILE_EXT = tar.gz
+DISTFILE = $(BIN)-$(VERSION).$(DISTFILE_EXT)
+
+dist:
+ if test -e $(DISTFILE) ; then echo "$(DISTFILE) already exists" ; exit 1 ; fi
+ git archive --format $(DISTFILE_EXT) --prefix $(BIN)-$(VERSION)/ v$(VERSION) >$(DISTFILE).tmp && mv $(DISTFILE).tmp $(DISTFILE)
+
all: $(BIN)
$(BIN): $(OBJ)
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2024-03-13 4:52 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-12 18:14 [gentoo-commits] proj/fifo-cronolog:master commit in: / Robin H. Johnson
-- strict thread matches above, loose matches on Subject: below --
2024-03-13 4:52 Robin H. Johnson
2024-03-12 18:14 Robin H. Johnson
2024-03-12 18:14 Robin H. Johnson
2024-03-12 18:14 Robin H. Johnson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox