Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qXQJO-006FVR-Cu for pgsql-general@arkaria.postgresql.org; Sat, 19 Aug 2023 18:04:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qXQJM-001fMr-Nt for pgsql-general@arkaria.postgresql.org; Sat, 19 Aug 2023 18:04:32 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qXQJM-001fMj-Br for pgsql-general@lists.postgresql.org; Sat, 19 Aug 2023 18:04:32 +0000 Received: from meldrar.postgresql.org ([2a02:c0:301:0:ffff::31]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qXQJF-0011HD-7k for pgsql-general@lists.postgresql.org; Sat, 19 Aug 2023 18:04:31 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=postgresql.org; s=20171124; h=Content-Transfer-Encoding:Content-Type: Message-ID:References:In-Reply-To:Subject:To:From:Date:MIME-Version:Sender: Reply-To:Cc:Content-ID:Content-Description; bh=LWmBT1CvbtefEq3nnGyhyTdnJh1l6YeGadraPYgiXYM=; b=21mAtQ3QL8VcDIPYV9bnirkDqH n0N2EMlMhqV1/4GY31CF9c3fchf2i8QRwEzUt8OM2Q/WxX8S+Tj3DTCeHJe1lrRlRHRGRzgG1sOyL n1tMbhvsL0VJYWXn1ig+BACRugPbiLNJp2GzVnoo/xyp/oidhNy8dV6GMhiQJdHITHFLZCyY5Ioeg BWt2Ql+hGMO+/okUCIiQLQKAnt+zStz6LgQFh3MvqjqhHeE+2URV7hZioJfTEnM2TKYsQFPrWmwFb WNi3bIU36eGakaZ7eK4Zj/VoY91jCuFb2PkhlC9UG/QLjV3VMce/IaVr5sX8uEcJbONgY2Tf5t6kQ jD42+3DQ==; Received: from meldrar.postgresql.org ([87.238.57.231] helo=webmail.postgresql.org) by meldrar.postgresql.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qXQJ9-002fVA-Tj for pgsql-general@lists.postgresql.org; Sat, 19 Aug 2023 18:04:23 +0000 MIME-Version: 1.0 Date: Sun, 20 Aug 2023 04:04:20 +1000 From: Justin Clift To: pgsql-general@lists.postgresql.org Subject: Re: PG minor version in data directory? In-Reply-To: <20230819091422.ivqyk22fmiu7folp@hjp.at> References: <20230819091422.ivqyk22fmiu7folp@hjp.at> User-Agent: Roundcube Webmail/1.4.13 Message-ID: <8653547ab62b71545f3ad87015877bbc@postgresql.org> X-Sender: justin@postgresql.org Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2023-08-19 19:14, Peter J. Holzer wrote: > On 2023-08-19 14:22:25 +1000, Justin Clift wrote: >> Thanks, that's what I figured. I'll have to keep state in a >> PG_VERSION_MINOR >> there or something. :) > > Wouldn't it be better to ask whatever system you use to install the > software for the version? In the general sense, yes. :) For the very specific use case I'm working with (!), things are a bit different. It's for this, if that helps with context: * https://github.com/pgautoupgrade/docker-pgautoupgrade * https://hub.docker.com/r/pgautoupgrade/pgautoupgrade <-- docker repo It's a docker container that people use for running PostgreSQL, but also has the ability to (automatically) upgrade the data files from older versions. That's the piece I'm working on. Such a thing is useful for people that need a PG docker container, and whose needs are fairly simple. They can use point at this one, and they'll have a self-upgrading PG version that's fairly "fire and forget". Thus far (1 month in), it seems to work ok (for us) and some other people. Am obviously looking to improve its capabilities over time too. :) + Justin