Created attachment 225058 [details]
- Added a POOLER option for support connection poolers (like PgBouncer, Odyssey, etc) in transaction mode. The option disables usage of prepared statements.
- Moved a plist from pkg-plist to Makefile.
- Added nginx before-condition to rc-script.
Some discussions about this:
(In reply to Dmitry Wagin from comment #1)
I got this:
===> Patching for hs-postgrest-7.0.1_4
===> Applying extra patch /usr/ports/www/hs-postgrest/files/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs
No file to patch. Skipping...
1 out of 1 hunks ignored--saving rejects to hasql-1.4.2/library/Hasql/Private/IO.hs.rej
Can't create hasql-1.4.2/library/Hasql/Private/IO.hs.rej, output is in /tmp/patchrq64xKQVnY9: No such file or directory
===> FAILED Applying extra patch /usr/ports/www/hs-postgrest/files/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs
Can you help to check this one?
BTW, if possible, please submit the patch with `git format-patch` which is easier for committer and other tools to apply. It's preferred but not strict requirement.
Created attachment 225498 [details]
The problem has been occurred after 1db88699b09ff53bf0029cb8a01dad1e7f646a4c ( https://cgit.freebsd.org/ports/commit/?id=1db88699b09ff53bf0029cb8a01dad1e7f646a4c )
Testing in my poudriere.
Is this part also necessary? nginx isn't listed as a dependency of this port:
diff --git a/www/hs-postgrest/files/postgrest.in b/www/hs-postgrest/files/postgrest.in
index 7dac382dd80a..7ad89ce8615a 100644
@@ -2,6 +2,7 @@
# PROVIDE: postgrest
# REQUIRE: LOGIN
+# BEFORE: nginx
# KEYWORD: shutdown
# Add postgrest_enable="YES" to /etc/rc.conf to enable PostgREST:
(In reply to Li-Wen Hsu from comment #6)
In most cases PostgREST (as a backend) are used with nginx (as a frontend). This change avoids race conditions at the start and stop.
A commit in branch main references this bug:
Author: Dmitry Wagin <firstname.lastname@example.org>
AuthorDate: 2021-06-02 11:45:46 +0000
Commit: Li-Wen Hsu <lwhsu@FreeBSD.org>
CommitDate: 2021-06-19 09:54:12 +0000
www/hs-postgrest: Added an option for support database connection poolers
Small cleanups included
www/hs-postgrest/Makefile | 33 +++++++++++++---------
...s_hasql-1.4.2_library_Hasql_Private_IO.hs (new) | 13 +++++++++
www/hs-postgrest/files/postgrest.in | 1 +
www/hs-postgrest/pkg-plist (gone) | 2 --
4 files changed, 34 insertions(+), 15 deletions(-)