File tree Expand file tree Collapse file tree 3 files changed +24
-8
lines changed Expand file tree Collapse file tree 3 files changed +24
-8
lines changed Original file line number Diff line number Diff line change @@ -303,16 +303,16 @@ jobs:
303
303
distribution : ' temurin'
304
304
305
305
- name : Set up Python
306
- uses : actions/setup-python@v5
307
- with :
308
- python-version : ${{env.PYTHON_VERSION}}
306
+ uses : actions/setup-python@v5
307
+ with :
308
+ python-version : ${{env.PYTHON_VERSION}}
309
309
310
- - name : Install Python dependencies
310
+ - name : Install Python dependencies
311
311
working-directory : ./scripts/anonymization
312
312
run : |
313
313
if [[ ${{matrix.benchmark}} == anonymization ]]; then
314
314
python -m pip install --upgrade pip
315
- pip install -r requirements.txt
315
+ pip install -r requirements.txt
316
316
else
317
317
echo "Dependency installation not necessary for benchmark"
318
318
fi
@@ -635,10 +635,11 @@ jobs:
635
635
ACCEPT_EULA : Y
636
636
SA_PASSWORD : SApassword1
637
637
options : >-
638
- --health-cmd " /opt/mssql-tools/bin/sqlcmd -S localhost -U sa -P SApassword1 -b -Q ' SELECT 1;'"
639
- --health-interval 10s
638
+ --health-cmd="find /opt/mssql-tools* /bin/ -name sqlcmd -executable -print -quit | xargs -t -I% sh -c '% -C - S localhost -U sa -P SApassword1 -b -Q \" SELECT 1;\" '"
639
+ --health-interval 5s
640
640
--health-timeout 5s
641
641
--health-retries 5
642
+ --health-start-period 5s
642
643
ports :
643
644
- 1433:1433
644
645
steps :
Original file line number Diff line number Diff line change @@ -6,6 +6,12 @@ services:
6
6
container_name : sqlserver
7
7
hostname : sqlserver
8
8
image : mcr.microsoft.com/mssql/server:latest
9
+ healthcheck :
10
+ test : ["CMD-SHELL", "find /opt/mssql-tools*/bin/ -name sqlcmd -executable -print -quit | xargs -t -I% sh -c '% -C -S localhost -U sa -P SApassword1 -b -Q \"SELECT 1;\"'"]
11
+ interval : 5s
12
+ timeout : 5s
13
+ retries : 5
14
+ start_period : 5s
9
15
environment :
10
16
ACCEPT_EULA : Y
11
17
SA_PASSWORD : SApassword1
Original file line number Diff line number Diff line change @@ -6,11 +6,20 @@ cd "$scriptdir/"
6
6
7
7
docker compose up -d
8
8
9
- network=$( docker ps --format " {{.Names}} {{.Networks}}" | awk ' ( $1 ~ /^' $BENCHBASE_PROFILE ' / ) { print $2 }' )
9
+ network=$( docker ps --format " {{.Names}} {{.Networks}}" | awk ' ( $1 ~ /^sqlserver / ) { print $2 }' )
10
10
11
11
# Also setup the database for use with the sample configs.
12
12
# See Also: .github/workflows/maven.yml
13
13
14
+ # Wait until ready
15
+ for i in {1..60}; do
16
+ if /usr/bin/docker inspect --format=" {{print .State.Health.Status}}" sqlserver | grep -q -x healthy; then
17
+ break
18
+ else
19
+ sleep 5
20
+ fi
21
+ done
22
+
14
23
function run_sqlcmd_in_docker() {
15
24
set -x
16
25
docker run --rm --network=$network --entrypoint /opt/mssql-tools/bin/sqlcmd mcr.microsoft.com/mssql-tools:latest \
You can’t perform that action at this time.
0 commit comments