Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Jul 2018 18:43:04 +0000 (UTC)
From:      Kurt Jaeger <pi@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r476014 - in head/archivers/urbackup-server: . files
Message-ID:  <201807311843.w6VIh48T065169@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pi
Date: Tue Jul 31 18:43:04 2018
New Revision: 476014
URL: https://svnweb.freebsd.org/changeset/ports/476014

Log:
  archivers/urbackup-server: add default config and log rotation (via newsyslog)
  
  PR:		227853
  Submitted by:	Kirk Coombs <freebsd@coombscloud.com> (maintainer)

Added:
  head/archivers/urbackup-server/files/urbackupsrv.conf.sample-daemon.in   (contents, props changed)
  head/archivers/urbackup-server/files/urbackupsrv.conf.sample-newsyslog   (contents, props changed)
Modified:
  head/archivers/urbackup-server/Makefile
  head/archivers/urbackup-server/files/pkg-message.in
  head/archivers/urbackup-server/files/urbackup_server.in
  head/archivers/urbackup-server/pkg-plist

Modified: head/archivers/urbackup-server/Makefile
==============================================================================
--- head/archivers/urbackup-server/Makefile	Tue Jul 31 18:41:30 2018	(r476013)
+++ head/archivers/urbackup-server/Makefile	Tue Jul 31 18:43:04 2018	(r476014)
@@ -2,6 +2,7 @@
 
 PORTNAME=	urbackup-server
 DISTVERSION=	2.2.11
+PORTREVISION=	1
 CATEGORIES=	archivers
 MASTER_SITES=	https://hndl.urbackup.org/Server/${DISTVERSION}/
 
@@ -24,9 +25,16 @@ CONFIGURE_ARGS=	--enable-packaging
 
 USE_RC_SUBR=	urbackup_server
 
-SUB_FILES=	pkg-message
+SUB_FILES=	pkg-message urbackupsrv.conf.sample-daemon
 
 post-install:
+	${MKDIR} ${STAGEDIR}${PREFIX}/etc/urbackup
+	${INSTALL_DATA} ${WRKDIR}/urbackupsrv.conf.sample-daemon \
+		${STAGEDIR}${PREFIX}/etc/urbackup/urbackupsrv.conf.sample
+	${MKDIR} ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d
+	${INSTALL_DATA} ${FILESDIR}/urbackupsrv.conf.sample-newsyslog \
+		${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d/urbackupsrv.conf.sample
+
 	${INSTALL_MAN} ${WRKSRC}/docs/urbackupsrv.1 ${STAGEDIR}${MANPREFIX}/man/man1
 
 .include <bsd.port.mk>

Modified: head/archivers/urbackup-server/files/pkg-message.in
==============================================================================
--- head/archivers/urbackup-server/files/pkg-message.in	Tue Jul 31 18:41:30 2018	(r476013)
+++ head/archivers/urbackup-server/files/pkg-message.in	Tue Jul 31 18:43:04 2018	(r476014)
@@ -6,10 +6,16 @@ archivers/urbackup-server includes an RC script:
 TO START URBACKUP SERVER ON BOOT:
 sysrc urbackup_server_enable=YES
 
-START MANUALLY:
+TO START MANUALLY:
 service urbackup_server start
 
-Once started, visit the following to configure:
+The server daemon's configuration file is located at:
+%%PREFIX%%/etc/urbackup/urbackupsrv.conf
+
+Log rotation can be configured at:
+%%PREFIX%%/etc/newsyslog.conf.d/urbackupsrv.conf
+
+Once started, configure backup settings and manage backups at:
 http://localhost:55414
 
 SECURITY WARNING:

Modified: head/archivers/urbackup-server/files/urbackup_server.in
==============================================================================
--- head/archivers/urbackup-server/files/urbackup_server.in	Tue Jul 31 18:41:30 2018	(r476013)
+++ head/archivers/urbackup-server/files/urbackup_server.in	Tue Jul 31 18:43:04 2018	(r476014)
@@ -25,6 +25,6 @@ load_rc_config $name
 command=%%PREFIX%%/bin/urbackupsrv
 pidfile=/var/run/urbackupsrv.pid
 
-command_args="run -d -w $pidfile"
+command_args="run -d -w $pidfile -c %%PREFIX%%/etc/urbackup/urbackupsrv.conf"
 
 run_rc_command "$1"

Added: head/archivers/urbackup-server/files/urbackupsrv.conf.sample-daemon.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/urbackup-server/files/urbackupsrv.conf.sample-daemon.in	Tue Jul 31 18:43:04 2018	(r476014)
@@ -0,0 +1,37 @@
+#
+# This is parsed as a key=value file
+#
+
+#Port for FastCGI requests
+FASTCGI_PORT=55413
+
+#Enable internal HTTP server
+HTTP_SERVER="true"
+
+#Port for the web interface
+#(if internal HTTP server is enabled)
+HTTP_PORT=55414
+
+#Log file name
+#If you change the LOGFILE, you should also change the "logfilename" in %%PREFIX%%/etc/newsyslog.conf.d/urbackupsrv.conf 
+LOGFILE="/var/log/urbackup.log"
+
+#Either debug,warn,info or error
+LOGLEVEL="warn"
+
+#Temporary file directory
+# -- this may get very large depending on the advanced settings
+DAEMON_TMPDIR="/tmp"
+
+#Tmp file directory for sqlite temporary tables.
+#You might want to put the databases on another filesystem than the other temporary files.
+#Default is the same as DAEMON_TMPDIR
+SQLITE_TMPDIR=""
+
+#Interfaces from which to send broadcasts. (Default: all).
+#Comma separated -- e.g. "eth0,eth1"
+BROADCAST_INTERFACES=""
+
+#User the urbackupsrv process runs as
+#If you change the USER, you should also change the "[owner:group]" in %%PREFIX%%/etc/newsyslog.conf.d/urbackupsrv.conf
+USER="urbackup"

Added: head/archivers/urbackup-server/files/urbackupsrv.conf.sample-newsyslog
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/archivers/urbackup-server/files/urbackupsrv.conf.sample-newsyslog	Tue Jul 31 18:43:04 2018	(r476014)
@@ -0,0 +1,2 @@
+# logfilename		[owner:group]		mode	count	size(kb)	when	flags	[/pid_file]	[sig_num]
+/var/log/urbackup.log	urbackup:urbackup	644  	10	5120		*	JC

Modified: head/archivers/urbackup-server/pkg-plist
==============================================================================
--- head/archivers/urbackup-server/pkg-plist	Tue Jul 31 18:41:30 2018	(r476013)
+++ head/archivers/urbackup-server/pkg-plist	Tue Jul 31 18:43:04 2018	(r476014)
@@ -4,6 +4,8 @@ bin/urbackupsrv
 @mode 0444
 man/man1/urbackupsrv.1.gz
 @mode 0644
+@sample etc/urbackup/urbackupsrv.conf.sample
+@sample etc/newsyslog.conf.d/urbackupsrv.conf.sample
 share/urbackup/server-license.txt
 share/urbackup/urbackup_ecdsa409k1.pub
 share/urbackup/www/css/bootstrap-flat-extras.chash-958e73e0ffd138319a4c6be29fa24392.min.css
@@ -140,3 +142,6 @@ share/urbackup/www/swf/flashExport.swf
 @owner urbackup
 @group urbackup
 @dir /var/urbackup
+@mode 0555
+@owner root
+@group wheel



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201807311843.w6VIh48T065169>