aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--www/Makefile1
-rw-r--r--www/py-searx/Makefile35
-rw-r--r--www/py-searx/distinfo2
-rw-r--r--www/py-searx/files/searx.in47
-rw-r--r--www/py-searx/pkg-descr3
5 files changed, 88 insertions, 0 deletions
diff --git a/www/Makefile b/www/Makefile
index 2da200e77d70..e1d187f56eb9 100644
--- a/www/Makefile
+++ b/www/Makefile
@@ -1770,6 +1770,7 @@
SUBDIR += py-scriptaculous
SUBDIR += py-seafdav
SUBDIR += py-seafobj
+ SUBDIR += py-searx
SUBDIR += py-selector
SUBDIR += py-selenium
SUBDIR += py-slimit
diff --git a/www/py-searx/Makefile b/www/py-searx/Makefile
new file mode 100644
index 000000000000..af2d56c6a726
--- /dev/null
+++ b/www/py-searx/Makefile
@@ -0,0 +1,35 @@
+# Created by: Loic Blot <loic.blot@unix-experience.fr>
+# $FreeBSD$
+
+PORTNAME= searx
+PORTVERSION= 0.8.1
+DISTVERSIONPREFIX= v
+CATEGORIES= www python
+PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER= lblot@unix-experience.fr
+COMMENT= Searx / a privacy-respecting, hackable metasearch engine
+
+LICENSE= AGPLv3
+
+RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}dateutil>0:devel/py-dateutil \
+ ${PYTHON_PKGNAMEPREFIX}Flask-Babel>0:devel/py-flask-babel \
+ ${PYTHON_PKGNAMEPREFIX}lxml>0:devel/py-lxml \
+ ${PYTHON_PKGNAMEPREFIX}yaml>0:devel/py-yaml \
+ ${PYTHON_PKGNAMEPREFIX}ndg_httpsclient>0:net/py-ndg_httpsclient \
+ ${PYTHON_PKGNAMEPREFIX}openssl>0:security/py-openssl \
+ ${PYTHON_PKGNAMEPREFIX}pygments>0:textproc/py-pygments \
+ ${PYTHON_PKGNAMEPREFIX}Flask>0:www/py-flask \
+ ${PYTHON_PKGNAMEPREFIX}requests>0:www/py-requests \
+ ${PYTHON_PKGNAMEPREFIX}werkzeug>0:www/py-werkzeug
+
+USE_RC_SUBR= searx
+
+USE_GITHUB= yes
+GH_ACCOUNT= asciimoo
+GH_PROJECT= searx
+
+USES= python
+USE_PYTHON= autoplist distutils concurrent
+
+.include <bsd.port.mk>
diff --git a/www/py-searx/distinfo b/www/py-searx/distinfo
new file mode 100644
index 000000000000..337b242b64ed
--- /dev/null
+++ b/www/py-searx/distinfo
@@ -0,0 +1,2 @@
+SHA256 (asciimoo-searx-v0.8.1_GH0.tar.gz) = 62cc8faa4aca47e7099f0cd85eff26f5cdaff4bf4ac0dc8b3f3cd315914d1a7c
+SIZE (asciimoo-searx-v0.8.1_GH0.tar.gz) = 1104093
diff --git a/www/py-searx/files/searx.in b/www/py-searx/files/searx.in
new file mode 100644
index 000000000000..56ae8b73cb6b
--- /dev/null
+++ b/www/py-searx/files/searx.in
@@ -0,0 +1,47 @@
+#!/bin/sh
+# $FreeBSD$
+
+# PROVIDE: searx
+# REQUIRE: DAEMON NETWORKING
+# BEFORE: LOGIN
+# KEYWORD: shutdown
+
+# Add the following lines to /etc/rc.conf to enable searx:
+# searx_enable="YES"
+#
+# searx_enable (bool): Set to YES to enable searx
+# Default: NO
+# searx_conf (str): searx configuration file
+# Default: ${PREFIX}/etc/searx.conf
+# searx_user (str): searx daemon user
+# Default: searx
+# searx_group (str): searx daemon group
+# Default: searx
+# searx_flags (str): Extra flags passed to searx
+
+. /etc/rc.subr
+
+name="searx"
+rcvar=searx_enable
+
+: ${searx_enable:="NO"}
+: ${searx_user:="www"}
+: ${searx_group:="www"}
+: ${searx_flags:=""}
+
+# daemon
+searx_pidfile="/var/run/${name}.pid"
+python="%%PREFIX%%/bin/python2.7"
+procname="%%PREFIX%%/lib/python2.7/site-packages/${name}/webapp.py"
+command=/usr/sbin/daemon
+command_args=" -c -f -P ${searx_pidfile} ${python} ${procname}"
+start_precmd="searx_precmd"
+
+searx_precmd()
+{
+ install -o ${searx_user} /dev/null ${searx_pidfile}
+}
+
+load_rc_config $name
+run_rc_command "$1"
+
diff --git a/www/py-searx/pkg-descr b/www/py-searx/pkg-descr
new file mode 100644
index 000000000000..a0b9d3e7fee6
--- /dev/null
+++ b/www/py-searx/pkg-descr
@@ -0,0 +1,3 @@
+A privacy-respecting, hackable metasearch engine.
+
+WWW: https://github.com/asciimoo/searx