Skip to content

Commit 01b5d1d

Browse files
authored
Merge branch 'main' into K8SPG-1086
2 parents 22a35a2 + 8fc9a8b commit 01b5d1d

6 files changed

Lines changed: 167 additions & 94 deletions

File tree

e2e-tests/release_versions

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,36 @@
11
IMAGE_OPERATOR=perconalab/percona-postgresql-operator:main
22

33
IMAGE_POSTGRESQL14=perconalab/percona-postgresql-operator:main-ppg14-postgres
4+
IMAGE_POSTGRESQL14_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-postgres14-community
5+
IMAGE_POSTGRESQL14_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-postgres14-community
46
IMAGE_PGBOUNCER14=perconalab/percona-postgresql-operator:main-pgbouncer14
57
IMAGE_POSTGIS14=perconalab/percona-postgresql-operator:main-ppg14-postgres-gis
68
IMAGE_BACKREST14=perconalab/percona-postgresql-operator:main-pgbackrest14
79

810
IMAGE_POSTGRESQL15=perconalab/percona-postgresql-operator:main-ppg15-postgres
11+
IMAGE_POSTGRESQL15_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-postgres15-community
12+
IMAGE_POSTGRESQL15_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-postgres15-community
913
IMAGE_PGBOUNCER15=perconalab/percona-postgresql-operator:main-pgbouncer15
1014
IMAGE_POSTGIS15=perconalab/percona-postgresql-operator:main-ppg15-postgres-gis
1115
IMAGE_BACKREST15=perconalab/percona-postgresql-operator:main-pgbackrest15
1216

1317
IMAGE_POSTGRESQL16=perconalab/percona-postgresql-operator:main-ppg16-postgres
18+
IMAGE_POSTGRESQL16_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-postgres16-community
19+
IMAGE_POSTGRESQL16_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-postgres16-community
1420
IMAGE_PGBOUNCER16=perconalab/percona-postgresql-operator:main-pgbouncer16
1521
IMAGE_POSTGIS16=perconalab/percona-postgresql-operator:main-ppg16-postgres-gis
1622
IMAGE_BACKREST16=perconalab/percona-postgresql-operator:main-pgbackrest16
1723

1824
IMAGE_POSTGRESQL17=perconalab/percona-postgresql-operator:main-ppg17-postgres
25+
IMAGE_POSTGRESQL17_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-postgres17-community
26+
IMAGE_POSTGRESQL17_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-postgres17-community
1927
IMAGE_PGBOUNCER17=perconalab/percona-postgresql-operator:main-pgbouncer17
2028
IMAGE_POSTGIS17=perconalab/percona-postgresql-operator:main-ppg17-postgres-gis
2129
IMAGE_BACKREST17=perconalab/percona-postgresql-operator:main-pgbackrest17
2230

2331
IMAGE_POSTGRESQL18=perconalab/percona-postgresql-operator:main-ppg18-postgres
32+
IMAGE_POSTGRESQL18_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-postgres18-community
33+
IMAGE_POSTGRESQL18_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-postgres18-community
2434
IMAGE_PGBOUNCER18=perconalab/percona-postgresql-operator:main-pgbouncer18
2535
IMAGE_POSTGIS18=perconalab/percona-postgresql-operator:main-ppg18-postgres-gis
2636
IMAGE_BACKREST18=perconalab/percona-postgresql-operator:main-pgbackrest18
@@ -30,7 +40,13 @@ IMAGE_PGBOUNCER19=perconalab/percona-postgresql-operator:main-pgbouncer19
3040
IMAGE_BACKREST19=perconalab/percona-postgresql-operator:main-pgbackrest19
3141
IMAGE_UPGRADE19=perconalab/percona-postgresql-operator:main-upgrade19
3242

43+
IMAGE_PGBOUNCER_COMMUNITY=perconalab/percona-postgresql-operator:main-pgbouncer-community
44+
IMAGE_PGBACKREST_COMMUNITY=perconalab/percona-postgresql-operator:main-pgbackrest-community
45+
3346
IMAGE_UPGRADE=perconalab/percona-postgresql-operator:main-upgrade
47+
IMAGE_UPGRADE_UBI8_COMMUNITY=perconalab/percona-postgresql-operator:main-ubi8-upgrade-community
48+
IMAGE_UPGRADE_UBI9_COMMUNITY=perconalab/percona-postgresql-operator:main-upgrade-community
49+
3450
IMAGE_LOGCOLLECTOR=perconalab/fluentbit:main-logcollector
3551

3652
IMAGE_PMM_CLIENT=perconalab/pmm-client:3-dev-latest

e2e-tests/run-community.csv

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
backup-enable-disable
2+
builtin-extensions
3+
cert-management-policy
4+
custom-envs
5+
custom-tls
6+
database-init-sql
7+
dynamic-configuration
8+
extra-volumes
9+
finalizers
10+
init-deploy
11+
ldap
12+
ldap-tls
13+
logical-replica
14+
one-pod
15+
operator-self-healing
16+
pgbouncer
17+
pitr
18+
repo-host-autogrow
19+
scaling
20+
self-healing
21+
sidecars
22+
standby-pgbackrest
23+
standby-streaming
24+
start-from-backup
25+
start-from-volumes
26+
tablespaces
27+
telemetry-transfer
28+
users

e2e-tests/tests/pg-tde-wal-encrypt/09-read-data.yaml

Lines changed: 18 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,35 @@
11
apiVersion: kuttl.dev/v1beta1
22
kind: TestStep
33
commands:
4-
- timeout: 60
4+
- timeout: 300
55
script: |-
66
set -o errexit
77
set -o xtrace
88
99
source ../../functions
1010
11-
primary=$(get_pod_by_role pg-tde-wal-encrypt primary name)
12-
echo "Primary pod: ${primary}"
13-
data=$(kubectl exec ${primary} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
11+
# enabling WAL encryption restarts the postgres process, so both the primary
12+
# election and the query itself can fail while the instances come back up
13+
read_from_primary() {
14+
local primary
15+
primary=$(get_pod_by_role pg-tde-wal-encrypt primary name)
16+
echo "Primary pod: ${primary}"
17+
[[ -n ${primary} ]] || return 1
18+
data=$(kubectl exec ${primary} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
19+
}
20+
21+
read_from_pod() {
22+
local pod=$1
23+
data=$(kubectl exec ${pod} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
24+
}
25+
26+
retry 12 5 read_from_primary
1427
kubectl create configmap -n "${NAMESPACE}" 09-read-from-primary --from-literal=data="${data}"
1528
1629
t=1
1730
for i in $(kubectl get pods -n "${NAMESPACE}" -l postgres-operator.crunchydata.com/cluster=pg-tde-wal-encrypt,postgres-operator.crunchydata.com/role=replica -o jsonpath='{.items[*].metadata.name}'); do
1831
echo "Replica pod: ${i}"
19-
data=$(kubectl exec ${i} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
32+
retry 12 5 read_from_pod "${i}"
2033
kubectl create configmap -n "${NAMESPACE}" 09-read-from-replica-${t} --from-literal=data="${data}"
2134
t=$((t+1))
2235
done

e2e-tests/tests/pg-tde-wal-encrypt/14-read-data.yaml

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,47 @@
11
apiVersion: kuttl.dev/v1beta1
22
kind: TestStep
33
commands:
4-
- timeout: 60
4+
- timeout: 300
55
script: |-
66
set -o errexit
77
set -o xtrace
88
99
source ../../functions
1010
11-
primary=$(get_pod_by_role pg-tde-wal-encrypt primary name)
12-
echo "Primary pod: ${primary}"
13-
data=$(kubectl exec ${primary} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
11+
# enabling WAL encryption restarts the postgres process, so both the primary
12+
# election and the query itself can fail while the instances come back up
13+
read_from_primary() {
14+
local primary
15+
primary=$(get_pod_by_role pg-tde-wal-encrypt primary name)
16+
echo "Primary pod: ${primary}"
17+
[[ -n ${primary} ]] || return 1
18+
data=$(kubectl exec ${primary} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
19+
}
20+
21+
read_from_pod() {
22+
local pod=$1
23+
data=$(kubectl exec ${pod} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
24+
}
25+
26+
retry 12 5 read_from_primary
1427
kubectl create configmap -n "${NAMESPACE}" 14-read-from-primary --from-literal=data="${data}"
1528
1629
t=1
1730
for i in $(kubectl get pods -n "${NAMESPACE}" -l postgres-operator.crunchydata.com/cluster=pg-tde-wal-encrypt,postgres-operator.crunchydata.com/role=replica -o jsonpath='{.items[*].metadata.name}'); do
1831
echo "Replica pod: ${i}"
19-
data=$(kubectl exec ${i} -n "${NAMESPACE}" -- bash -c 'psql -q -t -d myapp -c "SELECT * from myTable;"')
32+
retry 12 5 read_from_pod "${i}"
2033
kubectl create configmap -n "${NAMESPACE}" 14-read-from-replica-${t} --from-literal=data="${data}"
2134
t=$((t+1))
2235
done
2336
2437
# the backup was taken with the rotated vault credentials, so the restored
2538
# cluster must still be able to reach the principal key
26-
run_psql_command \
27-
"SELECT pg_tde_verify_key();" \
28-
"$(get_psql_uri pg-tde-wal-encrypt postgres)/myapp"
39+
verify_key() {
40+
run_psql_command \
41+
"SELECT pg_tde_verify_key();" \
42+
"$(get_psql_uri pg-tde-wal-encrypt postgres)/myapp"
43+
}
44+
retry 12 5 verify_key
2945
3046
# K8SPG-911: the restore Job renames the data directory on its way out and Patroni
3147
# moves it back, so check the keyring link still resolves afterwards.

go.mod

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ require (
88
github.com/cert-manager/cert-manager v1.21.1
99
github.com/go-logr/logr v1.4.4
1010
github.com/go-openapi/errors v0.22.8
11-
github.com/go-openapi/runtime v0.33.0
11+
github.com/go-openapi/runtime v0.33.1
1212
github.com/go-openapi/strfmt v0.27.0
13-
github.com/go-openapi/swag v0.28.0
14-
github.com/go-openapi/validate v0.26.3
13+
github.com/go-openapi/swag v0.29.1
14+
github.com/go-openapi/validate v0.26.4
1515
github.com/golang-jwt/jwt/v5 v5.3.1
1616
github.com/google/go-cmp v0.7.0
1717
github.com/google/uuid v1.6.0
@@ -25,10 +25,10 @@ require (
2525
github.com/pganalyze/pg_query_go/v6 v6.2.2
2626
github.com/pkg/errors v0.9.1
2727
github.com/robfig/cron/v3 v3.0.1
28-
github.com/sirupsen/logrus v1.10.0
29-
github.com/stretchr/testify v1.12.0
28+
github.com/sirupsen/logrus v1.10.1
29+
github.com/stretchr/testify v1.12.1
3030
github.com/xdg-go/stringprep v1.0.4
31-
go.nhat.io/grpcmock v0.34.0
31+
go.nhat.io/grpcmock v0.35.0
3232
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.70.0
3333
go.opentelemetry.io/otel v1.45.0
3434
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.45.0
@@ -39,7 +39,7 @@ require (
3939
go.uber.org/zap v1.28.0
4040
golang.org/x/crypto v0.55.0
4141
golang.org/x/tools v0.49.0
42-
google.golang.org/grpc v1.83.0
42+
google.golang.org/grpc v1.83.1
4343
gotest.tools/v3 v3.5.2
4444
k8s.io/api v0.36.4
4545
k8s.io/apiextensions-apiserver v0.36.4
@@ -70,23 +70,23 @@ require (
7070
github.com/go-ldap/ldap/v3 v3.4.13 // indirect
7171
github.com/go-logr/stdr v1.2.2 // indirect
7272
github.com/go-logr/zapr v1.3.0 // indirect
73-
github.com/go-openapi/analysis v0.26.0 // indirect
73+
github.com/go-openapi/analysis v0.26.1 // indirect
7474
github.com/go-openapi/jsonpointer v1.0.0 // indirect
7575
github.com/go-openapi/jsonreference v1.0.0 // indirect
76-
github.com/go-openapi/loads v0.25.0 // indirect
77-
github.com/go-openapi/runtime/server-middleware v0.30.0 // indirect
78-
github.com/go-openapi/spec v0.22.9 // indirect
79-
github.com/go-openapi/swag/cmdutils v0.28.0 // indirect
80-
github.com/go-openapi/swag/conv v0.28.0 // indirect
81-
github.com/go-openapi/swag/fileutils v0.28.0 // indirect
82-
github.com/go-openapi/swag/jsonutils v0.28.0 // indirect
83-
github.com/go-openapi/swag/loading v0.28.0 // indirect
84-
github.com/go-openapi/swag/mangling v0.28.0 // indirect
85-
github.com/go-openapi/swag/netutils v0.28.0 // indirect
86-
github.com/go-openapi/swag/pools v0.28.0 // indirect
87-
github.com/go-openapi/swag/stringutils v0.28.0 // indirect
88-
github.com/go-openapi/swag/typeutils v0.28.0 // indirect
89-
github.com/go-openapi/swag/yamlutils v0.28.0 // indirect
76+
github.com/go-openapi/loads v0.25.1 // indirect
77+
github.com/go-openapi/runtime/server-middleware v0.33.1 // indirect
78+
github.com/go-openapi/spec v0.22.10 // indirect
79+
github.com/go-openapi/swag/cmdutils v0.29.1 // indirect
80+
github.com/go-openapi/swag/conv v0.29.1 // indirect
81+
github.com/go-openapi/swag/fileutils v0.29.1 // indirect
82+
github.com/go-openapi/swag/jsonutils v0.29.1 // indirect
83+
github.com/go-openapi/swag/loading v0.29.1 // indirect
84+
github.com/go-openapi/swag/mangling v0.29.1 // indirect
85+
github.com/go-openapi/swag/netutils v0.29.1 // indirect
86+
github.com/go-openapi/swag/pools v0.29.1 // indirect
87+
github.com/go-openapi/swag/stringutils v0.29.1 // indirect
88+
github.com/go-openapi/swag/typeutils v0.29.1 // indirect
89+
github.com/go-openapi/swag/yamlutils v0.29.1 // indirect
9090
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
9191
github.com/go-viper/mapstructure/v2 v2.5.0 // indirect
9292
github.com/golang/protobuf v1.5.4 // indirect
@@ -103,7 +103,7 @@ require (
103103
github.com/mattn/go-isatty v0.0.20 // indirect
104104
github.com/mitchellh/go-homedir v1.1.0 // indirect
105105
github.com/mitchellh/mapstructure v1.5.0 // indirect
106-
github.com/oklog/ulid/v2 v2.1.1 // indirect
106+
github.com/oklog/ulid/v2 v2.1.2 // indirect
107107
github.com/pelletier/go-toml/v2 v2.2.4 // indirect
108108
github.com/rs/zerolog v1.34.0 // indirect
109109
github.com/sagikazarmark/locafero v0.12.0 // indirect
@@ -158,8 +158,8 @@ require (
158158
golang.org/x/time v0.15.0 // indirect
159159
gomodules.xyz/jsonpatch/v2 v2.5.0 // indirect
160160
google.golang.org/genproto/googleapis/api v0.0.0-20260803160001-6ac0973c030d // indirect
161-
google.golang.org/genproto/googleapis/rpc v0.0.0-20260803160001-6ac0973c030d // indirect
162-
google.golang.org/protobuf v1.36.12-0.20260120151049-f2248ac996af // indirect
161+
google.golang.org/genproto/googleapis/rpc v0.0.0-20260819154853-08b0e4226688 // indirect
162+
google.golang.org/protobuf v1.36.12 // indirect
163163
gopkg.in/inf.v0 v0.9.1 // indirect
164164
gopkg.in/yaml.v3 v3.0.1 // indirect
165165
k8s.io/klog/v2 v2.140.0 // indirect

0 commit comments

Comments
 (0)