Skip to content

Commit

Permalink
feat: add v17
Browse files Browse the repository at this point in the history
Signed-off-by: Niccolò Fei <[email protected]>
  • Loading branch information
NiccoloFei authored and sxd committed Oct 1, 2024
1 parent da8d784 commit de6ec7e
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 8 deletions.
6 changes: 3 additions & 3 deletions .github/generate-strategy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ set -eu

# Define an optional aliases for some major versions
declare -A aliases=(
[16]='latest'
[17]='latest'
)

# Define the current default UBI version
Expand Down Expand Up @@ -55,7 +55,7 @@ generator() {

# A "-beta" suffix will be appended to the beta images.
beta=""
if [ "${version}" -gt '16' ]; then
if [ "${version}" -gt '17' ]; then
beta="-beta"
# Split PG beta versions before the underscore
fullVersion=$(jq -r '.POSTGRES_VERSION | split("_") | .[0]' "${versionFile}")
Expand Down Expand Up @@ -170,7 +170,7 @@ generator_postgis() {

# A "-beta" suffix will be appended to the beta images.
beta=""
if [ "${version}" -gt '16' ]; then
if [ "${version}" -gt '17' ]; then
beta="-beta"
# Split PG beta versions before the underscore
fullVersion=$(jq -r '.POSTGRES_VERSION | split("_") | .[0]' "${versionFile}")
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# PostgreSQL Container Images by EnterpriseDB

Maintenance scripts to generate Immutable Application Containers
for all available PostgreSQL versions (12 to 16) based on
for all available PostgreSQL versions (12 to 17) based on
Red Hat Universal Base Images (UBI) 8 and 9:

- Standard minimal image - amd64/arm64
Expand Down
11 changes: 7 additions & 4 deletions UBI/update.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ if [ ${#versions[@]} -eq 0 ]; then
fi
versions=("${versions[@]%/}")

# Update this everytime a new major release of PostgreSQL is available
POSTGRESQL_LATEST_MAJOR_RELEASE=17

declare -A lastTagList=()
_raw_ubi_tags() {
local version="$1"; shift
Expand Down Expand Up @@ -61,7 +64,7 @@ get_postgresql_version() {
local pg_major="$1"; shift

local base_url="https://yum.postgresql.org"
if [ "$pg_major" -gt '16' ]; then
if [ "$pg_major" -gt "${POSTGRESQL_LATEST_MAJOR_RELEASE}" ]; then
base_url="$base_url/testing"
fi

Expand Down Expand Up @@ -163,7 +166,7 @@ get_postgis_version() {
local base_url="https://yum.postgresql.org"
local regexp='postgis\d+_'"${pg_major}"'-(\d+.\d+.\d+)-\d+.*rhel'"${os_version}"'.'"${arch}"'.rpm'

if [ "$pg_major" -gt '16' ]; then
if [ "$pg_major" -gt "${POSTGRESQL_LATEST_MAJOR_RELEASE}" ]; then
base_url="$base_url/testing"
regexp='postgis\d+_'"${pg_major}"'-(\d+.\d+.\d+)-.*.rhel'"${os_version}"'.'"${arch}"'.rpm'
fi
Expand Down Expand Up @@ -247,7 +250,7 @@ generate_redhat() {

# Unreleased PostgreSQL versions
yumOptions=""
if [ "$version" -gt '16' ]; then
if [ "$version" -gt "${POSTGRESQL_LATEST_MAJOR_RELEASE}" ]; then
yumOptions=" --enablerepo=pgdg${version}-updates-testing"
fi

Expand Down Expand Up @@ -421,7 +424,7 @@ generate_redhat_postgis() {

# Unreleased PostgreSQL versions
yumOptions=""
if [ "$version" -gt '16' ]; then
if [ "$version" -gt "${POSTGRESQL_LATEST_MAJOR_RELEASE}" ]; then
yumOptions=" --enablerepo=pgdg${version}-updates-testing"
fi

Expand Down

0 comments on commit de6ec7e

Please sign in to comment.