www/zoraxy: Add new port
www/zoraxy: Add Zoraxy reverse proxy Zoraxy is a general-purpose HTTP reverse proxy and forwarding tool written in Go. It provides a web-based interface for managing reverse proxy rules, routing, and access control. Features: - Web-based management interface - Reverse proxy and forwarding capabilities - Plugin support - Lightweight and self-contained (no external web server required) WWW: https://github.com/tobychui/zoraxy Sponsored by: Netzkommune GmbH
This commit is contained in:
@@ -326,7 +326,7 @@ _tlsrpt:*:382:
|
||||
cascade:*:383:
|
||||
omada:*:384:
|
||||
mtail:*:385:
|
||||
# free: 386
|
||||
zoraxy:*:386:
|
||||
# free: 387
|
||||
autopulse:*:388:
|
||||
ldap:*:389:
|
||||
|
||||
@@ -332,7 +332,7 @@ _tlsrpt:*:382:382::0:0:TLSRPT Daemon:/nonexistent:/usr/sbin/nologin
|
||||
cascade:*:383:383::0:0:Cascade Daemon:/var/db/cascade:/usr/sbin/nologin
|
||||
omada:*:384:384::0:0:Omada Wireless Controller:/nonexistent:/usr/sbin/nologin
|
||||
mtail:*:385:385::0:0:mtail:/nonexistent:/usr/sbin/nologin
|
||||
# free: 386
|
||||
zoraxy:*:386:386::0:0:Zoraxy Service:/nonexistent:/usr/sbin/nologin
|
||||
# free: 387
|
||||
autopulse:*:388:388::0:0:Autopulse Daemon:/nonexistent:/usr/sbin/nologin
|
||||
ldap:*:389:389::0:0:OpenLDAP Server:/nonexistent:/usr/sbin/nologin
|
||||
|
||||
@@ -2744,5 +2744,6 @@
|
||||
SUBDIR += zine-ssg
|
||||
SUBDIR += zgrab2
|
||||
SUBDIR += zola
|
||||
SUBDIR += zoraxy
|
||||
|
||||
.include <bsd.port.subdir.mk>
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
PORTNAME= zoraxy
|
||||
DISTVERSIONPREFIX= v
|
||||
DISTVERSION= 3.3.2
|
||||
CATEGORIES= www
|
||||
|
||||
MAINTAINER= joneum@bsd-mail.org
|
||||
COMMENT= General purpose HTTP reverse proxy and forwarding tool
|
||||
WWW= https://github.com/tobychui/zoraxy
|
||||
|
||||
LICENSE= AGPLv3
|
||||
LICENSE_FILE= ${WRKSRC:H}/LICENSE
|
||||
|
||||
USES= go:1.24+,modules
|
||||
USE_GITHUB= yes
|
||||
GH_ACCOUNT= tobychui
|
||||
GH_PROJECT= zoraxy
|
||||
|
||||
WRKSRC_SUBDIR= src
|
||||
|
||||
GO_MODULE= imuslab.com/zoraxy
|
||||
GO_MOD_DIST= github
|
||||
GO_TARGET= .
|
||||
|
||||
USERS= zoraxy
|
||||
GROUPS= zoraxy
|
||||
|
||||
USE_RC_SUBR= zoraxy
|
||||
SUB_FILES= pkg-message
|
||||
|
||||
post-install:
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/etc/zoraxy
|
||||
@${MKDIR} ${STAGEDIR}/var/db/zoraxy
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/share/zoraxy/plugins
|
||||
@${MKDIR} ${STAGEDIR}${PREFIX}/share/zoraxy/www
|
||||
|
||||
.include <bsd.port.mk>
|
||||
@@ -0,0 +1,5 @@
|
||||
TIMESTAMP = 1774736137
|
||||
SHA256 (go/www_zoraxy/tobychui-zoraxy-v3.3.2_GH0/go.mod) = 7c737157a18695e00430d98876c35c01c4cad5e5a55c846b1f035608653d04a2
|
||||
SIZE (go/www_zoraxy/tobychui-zoraxy-v3.3.2_GH0/go.mod) = 11935
|
||||
SHA256 (go/www_zoraxy/tobychui-zoraxy-v3.3.2_GH0/tobychui-zoraxy-v3.3.2_GH0.tar.gz) = 1208f2c3b1a7c4a5fa093d58a84653d4ab6e102909576240889330d8d0ea54d0
|
||||
SIZE (go/www_zoraxy/tobychui-zoraxy-v3.3.2_GH0/tobychui-zoraxy-v3.3.2_GH0.tar.gz) = 49204674
|
||||
@@ -0,0 +1,26 @@
|
||||
Zoraxy has been installed.
|
||||
|
||||
To enable Zoraxy at boot, add the following to /etc/rc.conf:
|
||||
|
||||
zoraxy_enable="YES"
|
||||
|
||||
Start the service with:
|
||||
|
||||
service zoraxy start
|
||||
|
||||
By default, Zoraxy listens on:
|
||||
|
||||
http://localhost:8000/
|
||||
|
||||
From another machine on the network, use:
|
||||
|
||||
http://<your-ip>:8000/
|
||||
|
||||
On first startup, open the web interface and complete the initial
|
||||
administrator account setup.
|
||||
|
||||
Optional rc.conf settings:
|
||||
|
||||
zoraxy_user="zoraxy"
|
||||
zoraxy_group="zoraxy"
|
||||
zoraxy_port=":8000"
|
||||
@@ -0,0 +1,74 @@
|
||||
#!/bin/sh
|
||||
|
||||
# PROVIDE: zoraxy
|
||||
# REQUIRE: LOGIN NETWORKING
|
||||
# KEYWORD: shutdown
|
||||
|
||||
. /etc/rc.subr
|
||||
|
||||
name="zoraxy"
|
||||
rcvar="zoraxy_enable"
|
||||
|
||||
load_rc_config $name
|
||||
|
||||
: ${zoraxy_enable:="NO"}
|
||||
: ${zoraxy_user:="zoraxy"}
|
||||
: ${zoraxy_group:="zoraxy"}
|
||||
: ${zoraxy_port:=":8000"}
|
||||
: ${zoraxy_conf:="%%PREFIX%%/etc/zoraxy"}
|
||||
: ${zoraxy_dbdir:="/var/db/zoraxy"}
|
||||
: ${zoraxy_plugindir:="%%PREFIX%%/share/zoraxy/plugins"}
|
||||
: ${zoraxy_webroot:="%%PREFIX%%/share/zoraxy/www"}
|
||||
: ${zoraxy_flags:=""}
|
||||
|
||||
pidfile="/var/run/${name}.pid"
|
||||
command="/usr/sbin/daemon"
|
||||
procname="%%PREFIX%%/bin/zoraxy"
|
||||
|
||||
required_files="${procname}"
|
||||
|
||||
start_precmd="${name}_prestart"
|
||||
stop_postcmd="${name}_poststop"
|
||||
status_cmd="${name}_status"
|
||||
|
||||
zoraxy_prestart()
|
||||
{
|
||||
install -d -o "${zoraxy_user}" -g "${zoraxy_group}" "${zoraxy_conf}"
|
||||
install -d -o "${zoraxy_user}" -g "${zoraxy_group}" "${zoraxy_dbdir}"
|
||||
install -d -o "${zoraxy_user}" -g "${zoraxy_group}" "${zoraxy_plugindir}"
|
||||
install -d -o "${zoraxy_user}" -g "${zoraxy_group}" "${zoraxy_webroot}"
|
||||
|
||||
if [ ! -f "${zoraxy_dbdir}/sys.uuid" ]; then
|
||||
/usr/bin/uuidgen > "${zoraxy_dbdir}/sys.uuid"
|
||||
chown "${zoraxy_user}:${zoraxy_group}" "${zoraxy_dbdir}/sys.uuid"
|
||||
chmod 0644 "${zoraxy_dbdir}/sys.uuid"
|
||||
fi
|
||||
}
|
||||
|
||||
zoraxy_start()
|
||||
{
|
||||
echo "Starting ${name}."
|
||||
${command} -f -p "${pidfile}" -u "${zoraxy_user}" \
|
||||
/usr/bin/env HOME="${zoraxy_dbdir}" \
|
||||
/bin/sh -c "cd '${zoraxy_dbdir}' && exec '${procname}' -port='${zoraxy_port}' ${zoraxy_flags}"
|
||||
}
|
||||
|
||||
zoraxy_poststop()
|
||||
{
|
||||
rm -f "${pidfile}"
|
||||
}
|
||||
|
||||
zoraxy_status()
|
||||
{
|
||||
if [ -f "${pidfile}" ] && /bin/kill -0 "$(cat "${pidfile}")" 2>/dev/null; then
|
||||
echo "${name} is running as pid $(cat "${pidfile}")."
|
||||
return 0
|
||||
fi
|
||||
|
||||
echo "${name} is not running."
|
||||
return 1
|
||||
}
|
||||
|
||||
start_cmd="${name}_start"
|
||||
|
||||
run_rc_command "$1"
|
||||
@@ -0,0 +1,11 @@
|
||||
Zoraxy is a general purpose HTTP reverse proxy and forwarding tool written in Go.
|
||||
|
||||
Features include:
|
||||
- reverse proxy with HTTP/2
|
||||
- redirection rules
|
||||
- TLS/SSL and ACME support
|
||||
- stream proxy for TCP and UDP
|
||||
- access control features
|
||||
- integrated uptime monitoring
|
||||
|
||||
This package installs Zoraxy as a native FreeBSD service.
|
||||
@@ -0,0 +1,5 @@
|
||||
bin/zoraxy
|
||||
@dir etc/zoraxy
|
||||
@dir /var/db/zoraxy
|
||||
@dir share/zoraxy/plugins
|
||||
@dir share/zoraxy/www
|
||||
Reference in New Issue
Block a user