From nobody Fri Jul 05 21:14:54 2024 X-Original-To: questions@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4WG5rR4tGDz5QW1F for ; Fri, 05 Jul 2024 21:15:03 +0000 (UTC) (envelope-from lysfjord.daniel@smokepit.net) Received: from smtp-out.smokepit.net (smtp-out.smokepit.net [18.200.56.156]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp-out.smokepit.net", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WG5rR31h9z4t7f for ; Fri, 5 Jul 2024 21:15:03 +0000 (UTC) (envelope-from lysfjord.daniel@smokepit.net) Authentication-Results: mx1.freebsd.org; none DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=smokepit.net; s=loke; h=Content-Transfer-Encoding:Content-Type:Message-ID: References:In-Reply-To:Subject:Cc:To:From:Date:MIME-Version:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=9G2+vIq7pGNxLgcH1TTIkWtXs5Jtzu0MWFIVZ8Sk35E=; b=d9Iz/q6/w+9eVybBP9mJRzprJw vQebdxIvv3uh5Cu2vOIP1sNm7Xig+WqvqSQdxsUr5L0F4oYKjcHtV5uK1gLlTqTFc5/8TBUn7V5Kb iGvz7FGb0MAdkgTO4axo6wZAURHS7EhTqki1e56iuHMA9qIPsxecmE0E4UanumbcFm3M=; Received: from ti0005a400-1212.bb.online.no ([80.212.65.198] helo=smokepit.net) by smtp-out.smokepit.net with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1sPqGd-0002ST-Pr; Fri, 05 Jul 2024 21:14:55 +0000 Received: from httpd.lan.smokepit.net ([10.0.3.114] helo=webmail.smokepit.net) by smokepit.net with esmtpsa (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.97.1 (FreeBSD)) (envelope-from ) id 1sPqGd-000000003KE-1zLK; Fri, 05 Jul 2024 23:14:55 +0200 List-Id: User questions List-Archive: https://lists.freebsd.org/archives/freebsd-questions List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-questions@freebsd.org Sender: owner-freebsd-questions@FreeBSD.org MIME-Version: 1.0 Date: Fri, 05 Jul 2024 23:14:54 +0200 From: Daniel Lysfjord To: Pat Cc: questions@freebsd.org Subject: Re: Setting default version in Poudriere In-Reply-To: References: Message-ID: <2a09efe671bc45d93f84ff69269e4388@smokepit.net> X-Sender: lysfjord.daniel@smokepit.net Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Report: Action: no action Symbol: FREEMAIL_ENVRCPT(0.00) Symbol: FROM_HAS_DN(0.00) Symbol: FROM_EQ_ENVFROM(0.00) Symbol: RCVD_TLS_ALL(0.00) Symbol: BAYES_HAM(-3.00) Symbol: TO_MATCH_ENVRCPT_ALL(0.00) Symbol: MIME_GOOD(-0.10) Symbol: RCPT_COUNT_TWO(0.00) Symbol: MID_RHS_MATCH_FROM(0.00) Symbol: FREEMAIL_TO(0.00) Symbol: RCVD_VIA_SMTP_AUTH(0.00) Symbol: ARC_NA(0.00) Symbol: MISSING_XM_UA(0.00) Symbol: RCVD_COUNT_ONE(0.00) Symbol: MIME_TRACE(0.00) Symbol: TO_DN_SOME(0.00) Message-ID: 2a09efe671bc45d93f84ff69269e4388@smokepit.net X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:16509, ipnet:18.200.0.0/16, country:US] X-Rspamd-Queue-Id: 4WG5rR31h9z4t7f On 2024-07-05 21:40, Pat wrote: > On Friday, July 5th, 2024 at 08:57, Edward Sanford Sutton, III > wrote: > >> >> >> On 7/4/24 13:57, Pat wrote: >> >> > Hello, >> > >> > Got a couple of rather silly question, but I can't find a definitive >> > answer to either. >> > >> > If I build PostgreSQL15-server, I get version 15.7. That is the latest >> > version, so not unexpected. >> > >> > I would like to build version 15.6. Ideally I would like to have both >> > versions available because for the most part I want to install 15.7, but >> > I need 15.6 at the moment. >> > >> > So my questions are: >> > How do I configure things to have both versions available? >> > If that is not possible, how do I set the default to be 15.6 for now, >> > with the intent of undoing that after my testing? >> >> >> There is only one port for version 15; to use 15.6 you need a copy of >> the ports tree with any git commit from >> 6fa897631d45dd11a5b1fcea5993590f9ccbef48 to before >> ade1c57e3a72ec9c4a7c02ce28dbfbd5efcce373 (probably >> de67baaee9ffaf88fa80dcda1f89d83df424d0a4 but I'm bad at sorting >> through >> git hashes). You could also manually patch the tree to have an older >> copy in place of the newer one. > > Thanks for taking the time to reply, and pinning to a specific commit > is in line with some of the information that I found, in particular > in the FreeBSD forums. But that leads to another question. > > I haven't done a lot with git in some time, but I am familiar with the > basics. I seem to recall that in order to identify a directory as a > git repo there should be a .git directory and a few other git related > items. I do not see any of that in any of the ports directories. For > instance: > > ls /usr/local/poudriere/ports/default/databases/postgresql15-server > total 259 > drwxr-xr-x 3 root wheel 13 May 16 13:07 ./ > drwxr-xr-x 1085 root wheel 1086 Jun 24 20:19 ../ > -rw-r--r-- 1 root wheel 801 May 16 13:07 Makefile > -rw-r--r-- 1 root wheel 187 May 16 13:07 distinfo > drwxr-xr-x 2 root wheel 18 May 16 13:07 files/ > -rw-r--r-- 1 root wheel 1238 Mar 1 11:12 pkg-descr > -rw-r--r-- 1 root wheel 482 Mar 1 11:12 pkg-install-server > -rw-r--r-- 1 root wheel 58816 Mar 1 11:12 pkg-plist-client > -rw-r--r-- 1 root wheel 10763 Mar 1 11:12 pkg-plist-contrib > -rw-r--r-- 1 root wheel 979 Mar 1 11:12 pkg-plist-plperl > -rw-r--r-- 1 root wheel 1389 Mar 1 11:12 pkg-plist-plpython > -rw-r--r-- 1 root wheel 197 Mar 1 11:12 pkg-plist-pltcl > -rw-r--r-- 1 root wheel 89992 May 16 13:07 pkg-plist-server > > Is that the right tree, or should I be looking elsewhere? I'm just > not sure where run the git commands from. If I knew that I might > could figure the rest out from there. > >> With poudriere, you can have multiple ports trees which once created >> you can then select for tasks such as `poudriere bulk -j 14 -p >> outdated databases/postgresql15-server` >> I'm not sure how easily you can have just a directory separate from >> the ports tree for poudriere to use in a port's place but tools such >> as >> ports-mgmt/portdowngrade may simplify the process for downgrading the >> port but I haven't tried it since git. >> If you want both versions available simultaneously from 1 poudriere >> run, I presume you need to add a new unique tree entry that is a copy >> of >> 15.6 under its own named path and add it to databaes's Makefile. If >> you >> are just doing some a/b testing where you want to keep bouncing back >> and >> forth, I'd just have the tree with the old version as a separate ports >> tree and do the poudriere build of it and the updated version as 2 >> separate repos then change which one pkg looks at and (force?) >> installation of packages for each test. > > Yeah, my intent here is to do some simple a/b testing prior to a > production upgrade. I think the easiest option is to just create > two jails, one at the current level, and one at 15.6. I just need to > figure out the pinning part and I'm probably good. > >> >> > Thanks, >> > Pat >> >> I would suggest just creating a port for postgres 15.6 in addition to the 15.7 that's already in the ports tree