From beec05ce1c73b0c8946b17ef1a56f594e77fdeea Mon Sep 17 00:00:00 2001 From: Mihir Kandoi Date: Thu, 25 Jun 2026 12:03:07 +0530 Subject: [PATCH] ci: restore postgres durability-off settings in install.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The fan-out moved fsync/synchronous_commit/full_page_writes=off into start-db.sh startup flags, but the Postgres workflow runs a postgres:13.3 service container and calls install.sh directly — it never runs start-db.sh. So those flags never reached the Postgres CI, regressing it to full durability on a commit-heavy suite. Re-apply them via ALTER SYSTEM (reloadable) in the DB == "postgres" path, where the service-container workflow executes. MariaDB is unaffected (DB != postgres). --- .github/helper/install.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/helper/install.sh b/.github/helper/install.sh index 263c12555bb..bb7c85d88e0 100644 --- a/.github/helper/install.sh +++ b/.github/helper/install.sh @@ -296,6 +296,15 @@ fi if [ "$DB" == "postgres" ];then echo "travis" | psql -h 127.0.0.1 -p 5432 -c "CREATE DATABASE test_frappe" -U postgres; echo "travis" | psql -h 127.0.0.1 -p 5432 -c "CREATE USER test_frappe WITH PASSWORD 'test_frappe'" -U postgres; + + # Disposable CI DB: durability off for speed (postgres fsyncs every commit by default, which + # dominates a commit-heavy suite). All reloadable, no restart. The postgres workflow runs a + # service-container DB and never calls start-db.sh, so the flags must be applied here. + echo "travis" | psql -h 127.0.0.1 -p 5432 -U postgres \ + -c "ALTER SYSTEM SET synchronous_commit = 'off'" \ + -c "ALTER SYSTEM SET fsync = 'off'" \ + -c "ALTER SYSTEM SET full_page_writes = 'off'" \ + -c "SELECT pg_reload_conf()"; fi cd ~/frappe-bench || exit