File tree Expand file tree Collapse file tree 3 files changed +9
-14
lines changed Expand file tree Collapse file tree 3 files changed +9
-14
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,6 @@ pipeline:
34
34
--build-arg PGVERSION="$PGVERSION" \
35
35
--build-arg BASE_IMAGE="$BASE_IMAGE" \
36
36
--build-arg PGOLDVERSIONS="14 15 16" \
37
- --build-arg TIMESCALEDB="2.17.2" \
38
37
-t "$ECR_TEST_IMAGE" \
39
38
--push .
40
39
@@ -64,7 +63,6 @@ pipeline:
64
63
--build-arg PGVERSION="$PGVERSION" \
65
64
--build-arg BASE_IMAGE="$BASE_IMAGE" \
66
65
--build-arg PGOLDVERSIONS="14 15 16" \
67
- --build-arg TIMESCALEDB="2.17.2" \
68
66
-t "$ECR_TEST_IMAGE" \
69
67
--push .
70
68
cdp-promote-image "$ECR_TEST_IMAGE"
@@ -96,7 +94,6 @@ pipeline:
96
94
--build-arg PGVERSION="$PGVERSION" \
97
95
--build-arg BASE_IMAGE="$BASE_IMAGE" \
98
96
--build-arg PGOLDVERSIONS="14 15 16" \
99
- --build-arg TIMESCALEDB="2.17.2" \
100
97
-t "$ECR_TEST_IMAGE" \
101
98
--push .
102
99
cdp-promote-image "$ECR_TEST_IMAGE"
Original file line number Diff line number Diff line change 1
1
ARG BASE_IMAGE=ubuntu:22.04
2
2
ARG PGVERSION=17
3
- ARG TIMESCALEDB="2.15.3 2.18.0"
4
3
ARG DEMO=false
5
4
ARG COMPRESS=false
6
5
ARG ADDITIONAL_LOCALES=
@@ -44,7 +43,6 @@ COPY build_scripts/base.sh /builddeps/
44
43
COPY --from=dependencies-builder /builddeps/*.deb /builddeps/
45
44
46
45
ARG PGVERSION
47
- ARG TIMESCALEDB
48
46
ARG TIMESCALEDB_APACHE_ONLY=true
49
47
ARG TIMESCALEDB_TOOLKIT=true
50
48
ARG COMPRESS
Original file line number Diff line number Diff line change @@ -121,18 +121,18 @@ for version in $DEB_PG_SUPPORTED_VERSIONS; do
121
121
" postgresql-${version} -pg-stat-kcache" \
122
122
" ${EXTRAS[@]} "
123
123
124
- # Clean up timescaledb versions except the highest compatible version
124
+ # Clean up timescaledb versions except the highest compatible and transition version
125
125
exclude_patterns=()
126
- exclude_patterns_tsl=()
127
- for ts_version in ${TIMESCALEDB} ; do
126
+ prev_highest_ver=" $ts_highest_ver "
127
+ ts_highest_ver=$( find " /usr/lib/postgresql/$version /lib/" -name ' timescaledb-2.*.so' | sed -rn ' s/.*timescaledb-([1-9]+\.[0-9]+\.[0-9]+)\.so$/\1/p' | sort -rV | head -n1)
128
+ if [ " $prev_highest_ver " != " $ts_highest_ver " ]; then
129
+ ts_transition_version=" $prev_highest_ver "
130
+ fi
131
+ for ts_version in " $ts_transition_version " " $ts_highest_ver " ; do
128
132
exclude_patterns+=(! -name timescaledb-" ${ts_version} " .so)
129
- exclude_patterns_tsl +=(! -name timescaledb-tsl-" ${ts_version} " .so)
133
+ exclude_patterns +=(! -name timescaledb-tsl-" ${ts_version} " .so)
130
134
done
131
- find /usr/lib/postgresql/" ${version} " /lib/ -name ' timescaledb-2.*.so' " ${exclude_patterns[@]} " -delete;
132
-
133
- if [ " ${TIMESCALEDB_APACHE_ONLY} " != " true" ]; then
134
- find /usr/lib/postgresql/" ${version} " /lib/ -name ' timescaledb-tsl-2.*.so' " ${exclude_patterns_tsl[@]} " -delete;
135
- fi
135
+ find " /usr/lib/postgresql/$version /lib/" \( -name ' timescaledb-2.*.so' -o -name ' timescaledb-tsl-2.*.so' \) " ${exclude_patterns[@]} " -delete
136
136
137
137
# Install 3rd party stuff
138
138
You can’t perform that action at this time.
0 commit comments