View | Details | Raw Unified | Return to bug 257074 | Differences between
and this patch

Collapse All | Expand All

(-)b/databases/go-pgweb/Makefile (-1 / +12 lines)
Lines 1-10 Link Here
1
PORTNAME=	pgweb
1
PORTNAME=	pgweb
2
DISTVERSIONPREFIX=	v
2
DISTVERSIONPREFIX=	v
3
DISTVERSION=	0.11.7
3
DISTVERSION=	0.11.7
4
PORTREVISION=	1
4
CATEGORIES=	databases www
5
CATEGORIES=	databases www
5
PKGNAMEPREFIX=	go-
6
PKGNAMEPREFIX=	go-
6
7
7
MAINTAINER=	ports@FreeBSD.org
8
MAINTAINER=	daniel@morante.net
8
COMMENT=	Web-based database browser for PostgreSQL
9
COMMENT=	Web-based database browser for PostgreSQL
9
10
10
LICENSE=	MIT
11
LICENSE=	MIT
Lines 15-18 GH_ACCOUNT= sosedoff Link Here
15
GO_PKGNAME=	github.com/sosedoff/pgweb
16
GO_PKGNAME=	github.com/sosedoff/pgweb
16
PLIST_FILES=	bin/pgweb
17
PLIST_FILES=	bin/pgweb
17
18
19
USE_RC_SUBR=	${PORTNAME}
20
21
SUB_FILES+=	pkg-message
22
SUB_LIST+=	PORTNAME=${PORTNAME} \
23
			PGWEBUSER=${USERS} \
24
			PGWEBGROUP=${GROUPS}
25
26
USERS=		www
27
GROUPS=		www
28
18
.include <bsd.port.mk>
29
.include <bsd.port.mk>
(-)b/databases/go-pgweb/files/pgweb.in (+50 lines)
Added Link Here
1
#!/bin/sh
2
#
3
#
4
# PROVIDE: %%PORTNAME%%
5
# REQUIRE: NETWORKING
6
# KEYWORD:
7
#
8
# Add the following lines to /etc/rc.conf to enable %%PORTNAME%%:
9
# %%PORTNAME%%_enable="YES"
10
#
11
# %%PORTNAME%%_enable (bool):		Set to YES to enable %%PORTNAME%%
12
#					Default: NO
13
# %%PORTNAME%%_bind (str):		HTTP server host
14
#					Default: localhost
15
# %%PORTNAME%%_listen (str):	HTTP server listen port
16
#					Default: 8081
17
# %%PORTNAME%%_user (str):		%%PORTNAME%% daemon user
18
#					Default: %%PGWEBUSER%%
19
# %%PORTNAME%%_group (str):		%%PORTNAME%% daemon group
20
#					Default: %%PGWEBGROUP%%
21
22
. /etc/rc.subr
23
24
name="%%PORTNAME%%"
25
rcvar="%%PORTNAME%%_enable"
26
load_rc_config $name
27
28
: ${%%PORTNAME%%_user:="www"}
29
: ${%%PORTNAME%%_group:="www"}
30
: ${%%PORTNAME%%_enable:="NO"}
31
: ${%%PORTNAME%%_bind:="localhost"}
32
: ${%%PORTNAME%%_flags=""}
33
: ${%%PORTNAME%%_facility:="daemon"}
34
: ${%%PORTNAME%%_priority:="debug"}
35
: ${%%PORTNAME%%_listen:="8081"}
36
37
procname="%%PREFIX%%/bin/${name}"
38
pidfile="/var/run/${name}.pid"
39
start_precmd="${name}_precmd"
40
command=/usr/sbin/daemon
41
command_args="-S -l ${%%PORTNAME%%_facility} -s ${%%PORTNAME%%_priority} -T ${name} -t ${name} -p ${pidfile} \
42
	${procname} --bind=${%%PORTNAME%%_bind} --listen=${%%PORTNAME%%_listen} ${%%PORTNAME%%_flags}"
43
44
%%PORTNAME%%_precmd()
45
{
46
	install -o ${%%PORTNAME%%_user} /dev/null ${pidfile}
47
}
48
49
run_rc_command "$1"
50
(-)b/databases/go-pgweb/files/pkg-message.in (+22 lines)
Added Link Here
1
[
2
{ type: install
3
  message: <<EOM
4
5
To run Pgweb at startup, enable it in your /etc/rc.conf:
6
sysrc pgweb_enable="YES"
7
8
To start Pgweb:
9
service pgweb start
10
11
Pgweb will listen on port 8081 and bind to localhost.  
12
This can be changed by setting "pgweb_bind" and "pgweb_listen" 
13
in /etc/rc.conf.
14
15
sysrc pgweb_bind="0.0.0.0" pgweb_listen="80"
16
17
Additional options can be set using "pgweb_flags". See 'pgweb --help' for a list
18
of all options.
19
20
EOM
21
}
22
]

Return to bug 257074