Skip to content

Commit 22c31fb

Browse files
committed
split sqlserver scripts
1 parent 2c068e3 commit 22c31fb

File tree

4 files changed

+13
-1
lines changed

4 files changed

+13
-1
lines changed

run-sqlserver.sh _run-sqlserver.sh

File renamed without changes.

env-sqlserver.sh

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
set -euo pipefail
44

5-
SQLSERVER_VERSION=2022-latest
65
CONTAINER_NAME=mb-sqlserver-db
76
HOST_PORT=1433
87
DB_NAME=master

run-sqlserver-latest.sh

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env bash
2+
3+
SOURCE_DIR=`dirname "${BASH_SOURCE[0]}"`
4+
5+
SQLSERVER_VERSION=2022-latest $SOURCE_DIR/_run-sqlserver.sh

run-sqlserver-oldest.sh

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env bash
2+
3+
SOURCE_DIR=`dirname "${BASH_SOURCE[0]}"`
4+
5+
SQLSERVER_VERSION=$(curl -s --request GET --url https://endoflife.date/api/mssqlserver.json |
6+
jq -r --arg today $(date +%Y%m%d) 'map(select((.eol == false) or ((.eol | gsub("-";"") | tonumber) > ($today | tonumber)))) | map(select(.releaseLabel | test("^[0-9]{4}$"))) | min_by(.releaseLabel) | .releaseLabel')
7+
8+
SQLSERVER_VERSION=$SQLSERVER_VERSION-latest $SOURCE_DIR/_run-sqlserver.sh

0 commit comments

Comments
 (0)