From: | Jason Petersen <jason(at)citusdata(dot)com> |
---|---|
To: | Devrim Gündüz <devrim(at)gunduz(dot)org> |
Cc: | Craig Ringer <craig(at)2ndquadrant(dot)com>, Daniel Farina <daniel(at)citusdata(dot)com>, pgsql-pkg-yum <pgsql-pkg-yum(at)postgresql(dot)org> |
Subject: | Re: [pgsql-pkg-yum] Amazon Linux PGDG Repo? |
Date: | 2018-03-22 18:39:17 |
Message-ID: | D2EBB988-3430-42A7-9C38-51A8F418DFBC@citusdata.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-pkg-yum |
> On Mar 22, 2018, at 3:42 AM, Devrim Gündüz <devrim(at)gunduz(dot)org> wrote:
>
> I don't know, I don't have access to Amazon Linux. Daniel?
Apart from EC2 having free instance types, Amazon Linux can now be run in Docker, so I don’t really understand the above? Or I guess you meant temporarily?
I emailed with Daniel about it a while back, here’s a snippet. Spoiler: there are macros…
> Begin forwarded message:
>
> From: Jason Petersen <jason(at)citusdata(dot)com>
> Subject: Re: [pgsql-pkg-yum] Amazon Linux PGDG Repo?
> Date: October 11, 2017 at 11:30:26 AM MDT
>
> […]
>
>> On Oct 10, 2017, at 5:18 PM, Daniel Farina <daniel(at)citusdata(dot)com <mailto:daniel(at)citusdata(dot)com>> wrote:
>>
>> Were you able to use macro detection to achieve this? I've done something similar by overriding the macros, e.g. via some "%global" statements. That's how I made packages.
>
> I started out doing that, then I got more curious where %rhel was defined and why it wasn’t defined in Amazon Linux. This led me to /etc/rpm/macros.disttag, which on Amazon Linux has this:
>
> # dist macros
>
> %amzn 1
> %dist .amzn1
> %amzn1 1
>
> Based on that I was able to add if statements to, for instance, include the python27-devel package (on RHEL it’s just python-devel, so RHEL logic wasn’t directly applicable). Where I didn’t know the “right” answer, I just defaulted to adding conditionals to have amzn behave identically to RHEL 6 (no systemd, no Python 3, etc.)
>
> With that I got a package build going of all the postgresql packages (libpq, contrib, etc. all included). If this is “standard” enough we [could] probably [… add these conditionals …] to the specfiles and add a buildfarm instance that just runs Amazon Linux in Docker and dumps the rpms to a shared volume for export.
So you can easily test for %amzn, %amzn1, or the contents of %dist…
--
Jason Petersen
Software Engineer | Citus Data
303.736.9255
jason(at)citusdata(dot)com
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Farina | 2018-03-26 18:28:20 | Re: How are debuginfo packages generated? |
Previous Message | Payal Singh | 2018-03-22 13:36:07 | Re: [pgsql-pkg-yum] Amazon Linux PGDG Repo? |