diff --git a/databases/proxysql/Makefile b/databases/proxysql/Makefile index b86e0d65216d..7741ea538d32 100644 --- a/databases/proxysql/Makefile +++ b/databases/proxysql/Makefile @@ -1,5 +1,5 @@ PORTNAME= proxysql -PORTVERSION= 2.6.4 +PORTVERSION= 2.6.6 CATEGORIES= databases MAINTAINER= zi@FreeBSD.org @@ -42,24 +42,17 @@ GH_ACCOUNT= sysown post-patch: @${REINPLACE_CMD} -e 's,/etc/,${ETCDIR}/,g' ${WRKSRC}/lib/ProxySQL_GloVars.cpp - @${REINPLACE_CMD} \ - -e 's|strftime(__buffer, 25, "%Y-%m-%d %H:%M:%S", __tm_info);|snprintf(__buffer, 3, "%s", "");|g' \ - -e 's,"%s \[,"%s\[,g' \ - -e '/__timer/d' \ - -e '/__tm_info/d' \ - ${WRKSRC}/include/proxysql_debug.h @${REINPLACE_CMD} \ -e 's,/var/lib,/var/db,g' \ -e '7s/^/errorlog="\/var\/log\/proxysql\/proxysql-error.log"\n\n/g' \ - -e '7s/^/pid="\/var\/run\/${PORTNAME}\/${PORTNAME}.pid"\n/g' \ + -e '7s/^/pidfile="\/var\/run\/${PORTNAME}\/${PORTNAME}.pid"\n/g' \ ${WRKSRC}/src/proxysql.cfg @${REINPLACE_CMD} \ - -e 's,grep,${LOCALBASE}/bin/grep,g' \ - -e 's,ln -fsT,ln -fs,' \ + -e 's,grep -P,${LOCALBASE}/bin/grep -P,g' \ + -e '/ export C/d' \ -e 's,PROXYSQLCLICKHOUSE=1 ,,g' \ -e 's,--enable-fastopen=false ,--enable-fastopen=false --enable-shared=no ,g' \ - ${WRKSRC}/Makefile ${WRKSRC}/deps/Makefile \ - ${WRKSRC}/lib/Makefile ${WRKSRC}/src/Makefile + ${WRKSRC}/Makefile ${WRKSRC}/deps/Makefile do-install: ${INSTALL_PROGRAM} ${WRKSRC}/src/proxysql ${STAGEDIR}${LOCALBASE}/sbin @@ -67,11 +60,8 @@ do-install: post-install: ${MKDIR} ${STAGEDIR}${ETCDIR} ${STAGEDIR}/var/db/${PORTNAME} \ ${STAGEDIR}/var/run/${PORTNAME} \ - ${STAGEDIR}${LOCALBASE}/etc/syslog.d \ ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d \ ${STAGEDIR}/var/log/${PORTNAME} - ${INSTALL_DATA} ${FILESDIR}/${PORTNAME}.conf \ - ${STAGEDIR}${LOCALBASE}/etc/syslog.d ${INSTALL_DATA} ${FILESDIR}/proxysql.conf-newsyslog \ ${STAGEDIR}${PREFIX}/etc/newsyslog.conf.d/proxysql.conf.sample ${INSTALL_DATA} ${WRKSRC}/src/proxysql.cfg \ diff --git a/databases/proxysql/distinfo b/databases/proxysql/distinfo index 373ba9b4f0dc..de4abe7a3946 100644 --- a/databases/proxysql/distinfo +++ b/databases/proxysql/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1724763891 -SHA256 (sysown-proxysql-2.6.4_GH0.tar.gz) = d1b018550fc5a0e16c697795060d98dd8c8d1d77e6ce184c2065c5d4374d26ab -SIZE (sysown-proxysql-2.6.4_GH0.tar.gz) = 50074326 +TIMESTAMP = 1727108943 +SHA256 (sysown-proxysql-2.6.6_GH0.tar.gz) = c447ac0c4532c6654cc648416e3dd1560824f67406f510efe52c4c6291a1ef4a +SIZE (sysown-proxysql-2.6.6_GH0.tar.gz) = 50425374 diff --git a/databases/proxysql/files/patch-deps_sqlite3_sqlite3__pass__exts.patch b/databases/proxysql/files/patch-deps_sqlite3_sqlite3__pass__exts.patch deleted file mode 100644 index 6fd69e2b56a6..000000000000 --- a/databases/proxysql/files/patch-deps_sqlite3_sqlite3__pass__exts.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- deps/sqlite3/sqlite3_pass_exts.patch.orig 2024-06-03 21:25:24 UTC -+++ deps/sqlite3/sqlite3_pass_exts.patch -@@ -11,7 +11,7 @@ - +//////////////////////////////////////////////////////////////////////////////// - + - +// ctype.h --+extern int toupper (int __c) __THROW; -++extern int toupper (int __c); - + - +// SHA256_crypt - +char * sha256_crypt_r (const char *key, const char *salt, char *buffer, int buflen); diff --git a/databases/proxysql/files/patch-lib_ProxySQL__Admin.cpp b/databases/proxysql/files/patch-lib_ProxySQL__Admin.cpp deleted file mode 100644 index deeac65cb508..000000000000 --- a/databases/proxysql/files/patch-lib_ProxySQL__Admin.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- lib/ProxySQL_Admin.cpp.orig 2024-04-05 16:24:43 UTC -+++ lib/ProxySQL_Admin.cpp -@@ -9507,7 +9507,7 @@ void ProxySQL_Admin::p_update_metrics() { - * @return On success, the number of currently opened file descriptors, '-1' otherwise. - */ - int32_t get_open_fds() { -- DIR* dir = opendir("/proc/self/fd"); -+ DIR* dir = opendir("/dev/fd"); - if (dir == NULL) { - proxy_error("'opendir()' failed with error: '%d'\n", errno); - return -1; diff --git a/databases/proxysql/files/patch-lib_ProxySQL__RESTAPI__Server.cpp b/databases/proxysql/files/patch-lib_ProxySQL__RESTAPI__Server.cpp deleted file mode 100644 index 72ae22c8e798..000000000000 --- a/databases/proxysql/files/patch-lib_ProxySQL__RESTAPI__Server.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- lib/ProxySQL_RESTAPI_Server.cpp.orig 2024-04-01 15:50:50 UTC -+++ lib/ProxySQL_RESTAPI_Server.cpp -@@ -346,7 +346,7 @@ ProxySQL_RESTAPI_Server::ProxySQL_RESTAPI_Server( - // NOTE: Right now ProxySQL is using the simplest mode of 'libhttpserver' for serving 'REST' queries, - // in the current mode concurrency on serving requests is low, and throughput is directly related with - // the time required to execute the target script, since each of the calls are blocking. -- ws = std::unique_ptr(new webserver(create_webserver(p))); -+ ws = std::unique_ptr(new webserver(create_webserver(p).start_method(http::http_utils::start_method_T::THREAD_PER_CONNECTION))); - // NOTE: Enable for benchmarking purposes. In this mode each request will be served by it's own thread. - // ws = std::unique_ptr(new webserver(create_webserver(p).start_method(http::http_utils::start_method_T::THREAD_PER_CONNECTION))); - auto sr = new sync_resource(); diff --git a/databases/proxysql/files/proxysql.conf b/databases/proxysql/files/proxysql.conf deleted file mode 100644 index 68fbfbcf23e8..000000000000 --- a/databases/proxysql/files/proxysql.conf +++ /dev/null @@ -1,2 +0,0 @@ -!proxysql -*.* /var/log/proxysql.log diff --git a/databases/proxysql/files/proxysql.conf-newsyslog b/databases/proxysql/files/proxysql.conf-newsyslog index 8a51ca3a6927..b67f04ed636d 100644 --- a/databases/proxysql/files/proxysql.conf-newsyslog +++ b/databases/proxysql/files/proxysql.conf-newsyslog @@ -1 +1 @@ -/var/log/proxysql.log root:wheel 640 10 1000 * JC +/var/log/proxysql.log root:wheel 640 10 1000 * JC /var/run/proxysql/proxysql.pid SIGUSR1 diff --git a/databases/proxysql/files/proxysql.in b/databases/proxysql/files/proxysql.in index 9220f30c0889..ad46d3f22ba3 100644 --- a/databases/proxysql/files/proxysql.in +++ b/databases/proxysql/files/proxysql.in @@ -33,15 +33,12 @@ load_rc_config $name : ${proxysql_args:=""} : ${proxysql_restart_delay:="10"} - +##### REMOVE daemon, allow proxysql to fork pidfile="/var/run/proxysql/proxysql.pid" -command="/usr/sbin/daemon" -proxysql_command="%%PREFIX%%/sbin/proxysql" -command_args="-rP ${pidfile} -S -R ${proxysql_restart_delay} \ - -T ${name} ${proxysql_command} \ - -f -c ${proxysql_config} \ - -D ${proxysql_datadir} \ - --no-version-check ${proxysql_args}" +command="%%PREFIX%%/sbin/proxysql" +command_args="-c ${proxysql_config} \ + -D ${proxysql_datadir} \ + --no-version-check ${proxysql_args}" required_files="${proxysql_config}" extra_commands="reload initial" reload_cmd=proxysql_reload diff --git a/databases/proxysql/pkg-message b/databases/proxysql/pkg-message index d7fdd1560919..c78b1cd41f14 100644 --- a/databases/proxysql/pkg-message +++ b/databases/proxysql/pkg-message @@ -10,10 +10,6 @@ If you have not yet enabled it, please do the following: To make this change persist through reboots, you must edit /etc/fstab: fdesc /dev/fd fdescfs rw 0 0 - -In order for logging to function, you must restart syslogd: - -# service syslogd restart EOM } ] diff --git a/databases/proxysql/pkg-plist b/databases/proxysql/pkg-plist index f49b893c5a16..cec65a43ac82 100644 --- a/databases/proxysql/pkg-plist +++ b/databases/proxysql/pkg-plist @@ -1,4 +1,3 @@ -etc/syslog.d/proxysql.conf sbin/proxysql @dir(,proxysql,0750) %%ETCDIR%% @sample(,proxysql,0640) %%ETCDIR%%/proxysql.cfg.sample @@ -6,5 +5,3 @@ sbin/proxysql @dir(proxysql,proxysql,0750) /var/db/proxysql @dir(proxysql,proxysql,0750) /var/run/proxysql @dir(proxysql,proxysql,0750) /var/log/proxysql -@postexec test -f /var/log/proxysql.log || touch /var/log/proxysql.log -@postexec chmod 600 /var/log/proxysql.log