Import vger-1.06

Vger is a gemini server supporting chroot, virtualhosts,
CGI, default language choice, redirections and MIME types
detection.

Vger design is relying on inetd and a daemon to take care of
TLS.  The idea is to delegate TLS and network to daemons
which proved doing it correctly, so vger takes its request
from stdin and output the result to stdout.

ok thfr@
This commit is contained in:
solene 2021-04-04 08:57:15 +00:00
parent a5a34d842a
commit 00e6ea9af4
5 changed files with 94 additions and 0 deletions

24
net/vger/Makefile Normal file
View File

@ -0,0 +1,24 @@
# $OpenBSD: Makefile,v 1.1.1.1 2021/04/04 08:57:15 solene Exp $
COMMENT = gemini server written in C used with inetd
V = 1.06
DISTNAME = vger-${V}
CATEGORIES = net
HOMEPAGE = https://tildegit.org/solene/vger/
MAINTAINER = Florian Viehweger <openbsd@out-of-creativity.de>
# BSD 2-clause
PERMIT_PACKAGE = Yes
# uses pledge()
# uses unveil()
WANTLIB += c
MASTER_SITES = https://tildegit.org/solene/vger/archive/
DISTFILES = vger-{}${V}${EXTRACT_SUFX}
WRKSRC = ${WRKDIR}/vger
.include <bsd.port.mk>

2
net/vger/distinfo Normal file
View File

@ -0,0 +1,2 @@
SHA256 (vger-1.06.tar.gz) = DRyVZPUJxoy/hAiHSzPE4hy0HJt89x0Q0inkrC9t6GA=
SIZE (vger-1.06.tar.gz) = 12937

8
net/vger/pkg/DESCR Normal file
View File

@ -0,0 +1,8 @@
Vger is a gemini server supporting chroot, virtualhosts,
CGI, default language choice, redirections and MIME types
detection.
Vger design is relying on inetd and a daemon to take care of
TLS. The idea is to delegate TLS and network to daemons
which proved doing it correctly, so vger takes its request
from stdin and output the result to stdout.

10
net/vger/pkg/PLIST Normal file
View File

@ -0,0 +1,10 @@
@comment $OpenBSD: PLIST,v 1.1.1.1 2021/04/04 08:57:15 solene Exp $
@newgroup _vger:865
@newuser _vger:865:865:daemon:Vger Gemini Server:/nonexistent:/sbin/nologin
@bin bin/vger
@man man/man8/vger.8
share/doc/pkg-readmes/${PKGSTEM}
@mode 755
@owner _vger
@group _vger
@sample /var/gemini/

50
net/vger/pkg/README Normal file
View File

@ -0,0 +1,50 @@
$OpenBSD: README,v 1.1.1.1 2021/04/04 08:57:15 solene Exp $
+-------------------------------------------------------------------------------
| Running ${PKGSTEM} on OpenBSD
+-------------------------------------------------------------------------------
Modify configuration files
==========================
In order to run Vger, you need to modify /etc/inetd.conf and /etc/relayd.conf.
inetd.conf
----------
127.0.0.1:11965 stream tcp nowait _vger ${TRUEPREFIX}/bin/vger vger
relayd.conf
-----------
log connection
tcp protocol "gemini" {
tls keypair hostname.example
}
relay "gemini" {
listen on hostname.example port 1965 tls
protocol "gemini"
forward to 127.0.0.1 port 11965
}
Enable respective services
==========================
You need to enable and start inetd and relayd.
$ rcctl enable relayd inetd
$ rcctl start relayd inetd
Firewall configuration
======================
Enable TCP port 1965.
Usage
=====
Vger will serve files named index.gmi if no explicit filename is given.
If this file doesn't exist and auto index is enabled, an index file
with a link to every file in the directory will be served.