Skip to content

Commit dbf4c50

Browse files
authored
Update all testing DBs, remove EOL versions (#379)
* Update all testing DBs, remove EOL versions Signed-off-by: Derek Nola <[email protected]> * Fix connection check for newer mariadb versions Signed-off-by: Derek Nola <[email protected]> --------- Signed-off-by: Derek Nola <[email protected]>
1 parent 277dca0 commit dbf4c50

File tree

5 files changed

+19
-14
lines changed

5 files changed

+19
-14
lines changed

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ ENV SRC_DIR=/go/src/github.com/k3s-io/kine
1515
WORKDIR ${SRC_DIR}/
1616

1717
# Validate needs everything in the project, so we separate it out for better caching
18-
FROM infra as validate
18+
FROM infra AS validate
1919
ARG SKIP_VALIDATE
2020
ENV SKIP_VALIDATE=${SKIP_VALIDATE}
2121
COPY . .
@@ -41,6 +41,6 @@ RUN --mount=type=cache,id=gomod,target=/go/pkg/mod \
4141
--mount=type=cache,id=gobuild,target=/root/.cache/go-build \
4242
./scripts/build
4343

44-
FROM scratch as binary
44+
FROM scratch AS binary
4545
ENV SRC_DIR=/go/src/github.com/k3s-io/kine
4646
COPY --from=build ${SRC_DIR}/bin /bin

scripts/test-run-cockroachdb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,8 @@ start-test() {
2828
export -f start-test
2929

3030
VERSION_LIST="\
31-
cockroachdb v20.2
32-
cockroachdb v20.1
33-
cockroachdb v19.2"
31+
cockroachdb v24.3
32+
cockroachdb v24.1"
3433

3534
while read ENGINE VERSION; do
3635
LABEL=$ENGINE-$VERSION DB_PASSWORD_ENV=POSTGRES_PASSWORD DB_IMAGE=docker.io/$ENGINE/cockroach:latest-$VERSION DB_ARGS="start-single-node --insecure" run-test

scripts/test-run-mysql

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,17 @@ start-test() {
55
local port=$(cat $TEST_DIR/databases/*/metadata/port)
66
local pass=$(cat $TEST_DIR/databases/*/metadata/password)
77
local image=$(cat $TEST_DIR/databases/*/metadata/image)
8+
# Starting with mariadb 11, you have to call to mariadb instead of mysql
9+
if [[ $image == *mariadb* ]]; then
10+
db_type="mariadb"
11+
else
12+
db_type="mysql"
13+
fi
814
DB_CONNECTION_TEST="
915
docker run --rm
1016
--name connection-test
1117
$image
12-
mysql
18+
$db_type
1319
--host=$ip
1420
--port=$port
1521
--user=root
@@ -23,11 +29,11 @@ start-test() {
2329
export -f start-test
2430

2531
VERSION_LIST="\
32+
mysql 8.4
2633
mysql 8.0
27-
mysql 5.7
34+
mariadb 11.4
2835
mariadb 10.11
29-
mariadb 10.5
30-
mariadb 10.4"
36+
mariadb 10.6"
3137

3238
while read ENGINE VERSION; do
3339
LABEL=$ENGINE-$VERSION DB_PASSWORD_ENV=MYSQL_ROOT_PASSWORD DB_IMAGE=docker.io/library/$ENGINE:$VERSION run-test

scripts/test-run-nats

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export -f start-test
1616
# test minimum supported version and most recent version of NATS
1717
VERSION_LIST="\
1818
nats 2.9.25
19-
nats 2.10.12"
19+
nats 2.10.23"
2020

2121
while read ENGINE VERSION; do
2222
LABEL=$ENGINE-$VERSION DB_PASSWORD_ENV=NATS_JS_PASSWORD DB_ARGS="-js" DB_IMAGE=docker.io/library/$ENGINE:$VERSION run-test

scripts/test-run-postgres

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ start-test() {
2323
export -f start-test
2424

2525
VERSION_LIST="\
26-
postgres 15.4
27-
postgres 14.9
28-
postgres 13.12
29-
postgres 12.16"
26+
postgres 17
27+
postgres 16
28+
postgres 15
29+
postgres 14"
3030

3131
while read ENGINE VERSION; do
3232
LABEL=$ENGINE-$VERSION DB_PASSWORD_ENV=POSTGRES_PASSWORD DB_IMAGE=docker.io/library/$ENGINE:$VERSION run-test

0 commit comments

Comments
 (0)