aboutsummaryrefslogtreecommitdiffstats
path: root/www
diff options
context:
space:
mode:
authorohauer <ohauer@FreeBSD.org>2014-07-24 07:27:39 +0800
committerohauer <ohauer@FreeBSD.org>2014-07-24 07:27:39 +0800
commit13a28e4aba06180097ac54709b75d426515529de (patch)
treed96fe92002b15f978e1aec56904c240d4e288d1c /www
parentdc93c7c2fa2d4d4236425e16cec43a515f83f850 (diff)
downloadfreebsd-ports-graphics-13a28e4aba06180097ac54709b75d426515529de.tar.gz
freebsd-ports-graphics-13a28e4aba06180097ac54709b75d426515529de.tar.zst
freebsd-ports-graphics-13a28e4aba06180097ac54709b75d426515529de.zip
- unbreak stage phase where the squid user is unknown
Noted by John Marino by PM
Diffstat (limited to 'www')
-rw-r--r--www/squidstats/Makefile3
-rw-r--r--www/squidstats/files/patch-graph__src__Makefile8
-rw-r--r--www/squidstats/pkg-plist4
3 files changed, 10 insertions, 5 deletions
diff --git a/www/squidstats/Makefile b/www/squidstats/Makefile
index cb3534c90e0..e3fead732f1 100644
--- a/www/squidstats/Makefile
+++ b/www/squidstats/Makefile
@@ -3,7 +3,7 @@
PORTNAME= squidstats
PORTVERSION= 54
-PORTREVISION= 2
+PORTREVISION= 3
CATEGORIES= www
MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE}
DISTNAME= squidstats-r${PORTVERSION}
@@ -20,6 +20,7 @@ SHEBANG_FILES= graph/src/stats.pl.in
USERS= squid
GROUPS= squid
+PLIST_SUB+= WWWOWN=${WWWOWN} SQUID_USER=${USERS}
SUB_FILES= pkg-message
diff --git a/www/squidstats/files/patch-graph__src__Makefile b/www/squidstats/files/patch-graph__src__Makefile
index 07d35f9e763..3adeb057152 100644
--- a/www/squidstats/files/patch-graph__src__Makefile
+++ b/www/squidstats/files/patch-graph__src__Makefile
@@ -1,5 +1,5 @@
---- ./graph/src/Makefile.orig 2014-07-19 13:30:29.000000000 +0200
-+++ ./graph/src/Makefile 2014-07-19 13:32:27.000000000 +0200
+--- ./graph/src/Makefile.orig 2009-01-07 19:20:02.000000000 +0100
++++ ./graph/src/Makefile 2014-07-24 01:02:02.000000000 +0200
@@ -33,21 +33,21 @@
$(RM) stats.pl config.ini graph-summary.cgi
@@ -25,8 +25,8 @@
- $(INSTALL) -m 0644 templates.conf $(ETCDIR)/templates.conf
- $(INSTALL) -m 0644 snmp_monitor.cfg $(ETCDIR)/snmp_monitor.cfg
- $(INSTALL) -m 0644 graph.css $(WEB_DATADIR)/graph.css
-+ $(INSTALL_DIR) -m 0755 -o $(WEB_USER) $(DESTDIR)$(GRAPH_DATADIR)
-+ $(INSTALL_DIR) -m 0755 -o $(STATS_USER) $(DESTDIR)$(RRD_DATADIR)
++ $(INSTALL_DIR) -m 0755 $(DESTDIR)$(GRAPH_DATADIR)
++ $(INSTALL_DIR) -m 0755 $(DESTDIR)$(RRD_DATADIR)
+ $(INSTALL_DIR) -m 0755 $(DESTDIR)$(WEB_DATADIR)
+ $(INSTALL_DIR) -m 0755 $(DESTDIR)$(CGIDIR)
+ $(INSTALL_DIR) -m 0755 $(DESTDIR)$(ETCDIR)
diff --git a/www/squidstats/pkg-plist b/www/squidstats/pkg-plist
index 65bfaf78b49..c727ba9b54b 100644
--- a/www/squidstats/pkg-plist
+++ b/www/squidstats/pkg-plist
@@ -24,6 +24,10 @@ www/cgi-bin/graph-summary.cgi
@dirrm %%DATADIR%%/templates
@dirrm %%DATADIR%%
@dirrmtry www/cgi-bin
+@cwd /
+@comment set directory owner
+@exec chown -R %%WWWOWN%% "/var/db/squidstats/graphs"
+@exec chown -R %%SQUID_USER%% "/var/db/squidstats/rrd"
@unexec rmdir "/var/db/squidstats/graphs" >/dev/null 2>&1 || :
@unexec rmdir "/var/db/squidstats/rrd" >/dev/null 2>&1 || :
@unexec rmdir "/var/db/squidstats" >/dev/null 2>&1 || :