Skip to content

Commit 9ab4d1b

Browse files
pgpool2- add iamguarded build package (#77219)
Signed-off-by: Anushka Mittal <anushka.mittal@chainguard.dev> Co-authored-by: Anushka Mittal <anushka.mittal@chainguard.dev>
1 parent d16a202 commit 9ab4d1b

File tree

1 file changed

+39
-2
lines changed

1 file changed

+39
-2
lines changed

pgpool2-4.6.yaml

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package:
22
name: pgpool2-4.6
33
version: "4.6.5"
4-
epoch: 1
4+
epoch: 2
55
description: Middleware that works between PostgreSQL servers and a PostgreSQL database client.
66
copyright:
77
- license: BSD-3-Clause AND MIT
@@ -144,6 +144,44 @@ subpackages:
144144
stat /opt/pgpool-II/bin/start.sh
145145
stat /opt/pgpool-II/bin/entrypoint.sh
146146
147+
# iamguarded variant of pgpool2 with a different confdir
148+
- name: ${{package.name}}-iamguarded
149+
description: "Iamguarded pkg that builds with specific confdir"
150+
dependencies:
151+
provides:
152+
- pgpool2-iamguarded=${{package.full-version}}
153+
runtime:
154+
- bash
155+
- postgresql
156+
- postgresql-client
157+
pipeline:
158+
- uses: autoconf/configure
159+
with:
160+
opts: |
161+
--prefix=/opt/iamguarded/pgpool --sysconfdir=/opt/iamguarded/pgpool/etc --libdir=/opt/iamguarded/pgpool/lib --with-openssl
162+
# build src/parser explicitly to avoid build failures due to missing parser files with -j flag
163+
- runs: |
164+
make -C src/parser V=1
165+
- uses: autoconf/make
166+
with:
167+
opts: "clean" # The binary embeds the sysconfdir path at build time into the binary, so we do a clean rebuild.
168+
- uses: autoconf/make-install
169+
- uses: strip
170+
- runs: |
171+
mkdir -p "${{targets.contextdir}}/var/run/pgpool"
172+
mkdir -p ${{targets.contextdir}}/usr/bin/
173+
# To enable backwards compatibility with existing iamguarded-compat package, we copy binaries to /usr/bin
174+
cp -p ${{targets.contextdir}}/opt/iamguarded/pgpool/bin/* ${{targets.contextdir}}/usr/bin/
175+
test:
176+
pipeline:
177+
- uses: test/tw/ver-check
178+
with:
179+
bins: "/opt/iamguarded/pgpool/bin/pgpool"
180+
version: ${{package.version}}
181+
- uses: test/tw/help-check
182+
with:
183+
bins: "/opt/iamguarded/pgpool/bin/pgpool"
184+
147185
- name: ${{package.name}}-iamguarded-compat
148186
description: "Compatibility package for iamguarded variant of pgpool2"
149187
dependencies:
@@ -211,7 +249,6 @@ subpackages:
211249
package: pgpool2
212250
version: ${{vars.major-version}}
213251
- runs: |
214-
test -f /opt/iamguarded/pgpool/bin/pgpool
215252
test -f /opt/iamguarded/postgresql/bin/psql
216253
217254
update:

0 commit comments

Comments
 (0)