From patchwork Sat Nov 16 13:48:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicolas Graves X-Patchwork-Id: 70445 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 1B4D327BBEA; Sat, 16 Nov 2024 13:49:40 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_BLOCKED, RCVD_IN_VALIDITY_CERTIFIED,RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE, SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3652227BBE2 for ; Sat, 16 Nov 2024 13:49:37 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tCJAi-0004dM-6U; Sat, 16 Nov 2024 08:49:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tCJAd-0004cm-EJ for guix-patches@gnu.org; Sat, 16 Nov 2024 08:49:03 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tCJAd-0003u9-4D for guix-patches@gnu.org; Sat, 16 Nov 2024 08:49:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:From:To:In-Reply-To:References:Subject; bh=ic7rPgttynr+NzhN2/VirL8KF08rNBUjmeH74Lf1zZs=; b=Q17qlHaK2MXHLQiZb5p52AcvtJDvNTen5Fn6N08rppPeVGIKlnEnkSEUauuOw72wqnLf4ob2SjQqyeaaLyD8JiIXfswXHBToYfUDI/2oxLhYy0SHSc5Cv5BUWrkGaE0j7J/PlRIBXR+tfRz0QkEm7R3QFhNoLEcI8HJX8dnHJV6MeHGqjvjZLbR8EDDSvoBZQoIoUVoqrOhv20eJWYGfFIKREFldfQtyBUBiAajnUuX7pmo3i43i6w8WgDxvMjvvwXfUEIBxhcF6KKm7YK93VL75479xF6CryRjd5s+DI+WZ77UNovR5c6H5mVIV9rFiiNOSYQVrekEvLDcvaw4EsA==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tCJAc-0003WC-Uk for guix-patches@gnu.org; Sat, 16 Nov 2024 08:49:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74058] [PATCH v8 1/2] gnu: postgresql-configuration: Unset default postgresql. References: <20241028105741.12834-1-ngraves@ngraves.fr> In-Reply-To: <20241028105741.12834-1-ngraves@ngraves.fr> Resent-From: Nicolas Graves Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 16 Nov 2024 13:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74058 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74058@debbugs.gnu.org Cc: Nicolas Graves Received: via spool by 74058-submit@debbugs.gnu.org id=B74058.173176490513433 (code B ref 74058); Sat, 16 Nov 2024 13:49:02 +0000 Received: (at 74058) by debbugs.gnu.org; 16 Nov 2024 13:48:25 +0000 Received: from localhost ([127.0.0.1]:52537 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tCJA0-0003Ub-F2 for submit@debbugs.gnu.org; Sat, 16 Nov 2024 08:48:24 -0500 Received: from 9.mo550.mail-out.ovh.net ([178.32.108.172]:35205) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tCJ9v-0003UN-75 for 74058@debbugs.gnu.org; Sat, 16 Nov 2024 08:48:23 -0500 Received: from director7.ghost.mail-out.ovh.net (unknown [10.108.9.136]) by mo550.mail-out.ovh.net (Postfix) with ESMTP id 4XrFb54brvz1VMB for <74058@debbugs.gnu.org>; Sat, 16 Nov 2024 13:48:17 +0000 (UTC) Received: from ghost-submission-5b5ff79f4f-n9xw7 (unknown [10.110.96.192]) by director7.ghost.mail-out.ovh.net (Postfix) with ESMTPS id F07121FD32; Sat, 16 Nov 2024 13:48:16 +0000 (UTC) Received: from ngraves.fr ([37.59.142.100]) by ghost-submission-5b5ff79f4f-n9xw7 with ESMTPSA id zJGgG6CiOGdupQAA1rk8cA (envelope-from ); Sat, 16 Nov 2024 13:48:16 +0000 Authentication-Results: garm.ovh; auth=pass (GARM-100R003f3e64208-a523-4936-987c-ff022d77ecbb, DCC5B34D136351FDCD74B46CD4CC48AA15126211) smtp.auth=ngraves@ngraves.fr X-OVh-ClientIp: 90.92.117.144 Date: Sat, 16 Nov 2024 14:48:02 +0100 Message-ID: <20241116134811.4660-1-ngraves@ngraves.fr> X-Mailer: git-send-email 2.46.0 MIME-Version: 1.0 X-Ovh-Tracer-Id: 11718647706040197858 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeefuddrvdeigdehgecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfqggfjpdevjffgvefmvefgnecuuegrihhlohhuthemucehtddtnecunecujfgurhephffvvefufffkofgggfestdekredtredttdenucfhrhhomheppfhitgholhgrshcuifhrrghvvghsuceonhhgrhgrvhgvshesnhhgrhgrvhgvshdrfhhrqeenucggtffrrghtthgvrhhnpeekffegteffgfffjeegjedvfffgtddvueeutefgfeeuvdejgedvgeejjeevueeuveenucfkphepuddvjedrtddrtddruddpledtrdelvddruddujedrudeggedpfeejrdehledrudegvddruddttdenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpeduvdejrddtrddtrddupdhmrghilhhfrhhomhepnhhgrhgrvhgvshesnhhgrhgrvhgvshdrfhhrpdhnsggprhgtphhtthhopedupdhrtghpthhtohepjeegtdehkeesuggvsggsuhhgshdrghhnuhdrohhrghdpoffvtefjohhsthepmhhoheehtdgmpdhmohguvgepshhmthhpohhuth DKIM-Signature: a=rsa-sha256; bh=ic7rPgttynr+NzhN2/VirL8KF08rNBUjmeH74Lf1zZs=; c=relaxed/relaxed; d=ngraves.fr; h=From; s=ovhmo4487190-selector1; t=1731764897; v=1; b=4M+lQez8Z6KI5eMs5L9u1SRzd6srzJA0NF/pWwwjJWgmVtJsJCAEPnTmxuLY8HLAa9t6jWM4 YYZ4r1EqWF9X+z0KEhyofK4NAc4nbRe4vF6DpfDWqoMT/rXKfqyTCDXYrAZesuwCkwukAZS8xJ8 ChQwiMjTdcPTooAeNFHbiALmwp0x9hnZfRxM/eb2vHL4l4PJZc9RYnZd++nRNkV+3RhKvboalFT ZXG/Y1RxgQduc75mIVH8nFCXbWkc9N/8HUyGwYi+yRchd4v9ek1W7ybscemGwevBJfklSU+3/PR VqetYm2iHhlSAqVwxXaS70f8pcvF3gOFvKCt3lnErmYFw== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Nicolas Graves X-ACL-Warn: , Nicolas Graves via Guix-patches X-Patchwork-Original-From: Nicolas Graves via Guix-patches via From: Nicolas Graves Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/services/databases.scm (postgresql-configuration)[postgresql]: Unset default. (postgresql-service-type): Remove default-value. (postgresql-service): Revert default to postgresql-10 (rationale: We can remove this service at the same time than postgresql-10, in something like 6 months to a year). * doc/guix.texi: Remove postgresql default reference in documentation. --- doc/guix.texi | 2 +- gnu/services/databases.scm | 10 ++++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 2ab78d6237..ba4bd2cc79 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -26247,7 +26247,7 @@ Data type representing the configuration for the @code{postgresql-service-type}. @table @asis -@item @code{postgresql} (default: @code{postgresql}) +@item @code{postgresql} PostgreSQL package to use for the service. @item @code{port} (default: @code{5432}) diff --git a/gnu/services/databases.scm b/gnu/services/databases.scm index 0933eb5e79..e8a4acc996 100644 --- a/gnu/services/databases.scm +++ b/gnu/services/databases.scm @@ -167,8 +167,11 @@ (define contents (define-record-type* postgresql-configuration make-postgresql-configuration postgresql-configuration? - (postgresql postgresql-configuration-postgresql ;file-like - (default postgresql)) + ;; Setting no default ensures that the user sets its current postgresql + ;; explicitely. Since major upgrades currently require a manual migration + ;; of the database, this way the user is responsible for upgrading properly. + ;; MAYBE TODO: Write an action to automatically upgrade in Guix. + (postgresql postgresql-configuration-postgresql) ;file-like (port postgresql-configuration-port (default 5432)) (locale postgresql-configuration-locale @@ -343,10 +346,9 @@ (define postgresql-service-type (service-extension profile-service-type (compose list postgresql-configuration-postgresql)))) - (default-value (postgresql-configuration)) (description "Run the PostgreSQL database server."))) -(define-deprecated (postgresql-service #:key (postgresql postgresql) +(define-deprecated (postgresql-service #:key (postgresql postgresql-10) (port 5432) (locale "en_US.utf8") (config-file (postgresql-config-file))