Skip to content

Commit 9a0a705

Browse files
authored
Enable running integration test within VS (#239)
* Enable running integration test in VS * Update docker compose template * Remove nugetdefence scan * Cleanup minio after scenario * Update messaging lib to 0.1.11 * Use ubuntu-22.04 for integration test Signed-off-by: Victor Chang <[email protected]>
1 parent 697c7fc commit 9a0a705

File tree

83 files changed

+6040
-5710
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

83 files changed

+6040
-5710
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -149,13 +149,6 @@ jobs:
149149
run: dotnet build -c ${{ env.BUILD_CONFIG }} --nologo ${{ env.SOLUTION }}
150150
working-directory: ./src
151151

152-
- name: NuGetDefense Scanning
153-
continue-on-error: true
154-
run: |
155-
sed -i "s/OSSINDEXAPI_TOKEN/$OSSINDEXAPI_TOKEN/g" NuGetDefense.json
156-
sed -i "s/OSSINDEXAPI_USERNAME/$OSSINDEXAPI_USERNAME/g" NuGetDefense.json
157-
nugetdefense -p src/${{ env.SOLUTION }} --settings-file NuGetDefense.json
158-
159152
- name: Secret detection
160153
uses: gitleaks/[email protected]
161154

@@ -237,9 +230,8 @@ jobs:
237230
verbose: true
238231

239232
integration-test:
240-
runs-on: ubuntu-latest
233+
runs-on: ubuntu-22.04
241234
timeout-minutes: 30
242-
needs: [build]
243235
strategy:
244236
matrix:
245237
feature: [AcrApi, DicomDimseScp, DicomDimseScu, DicomWebExport, DicomWebStow, HealthLevel7, Fhir]
@@ -285,7 +277,6 @@ jobs:
285277
name: integration-${{ matrix.feature }}
286278
path: |
287279
${{ github.workspace }}/LivingDoc.html
288-
${{ github.workspace }}/metrics.log
289280
${{ github.workspace }}/services.log
290281
${{ github.workspace }}/run.log
291282
retention-days: 30

doc/dependency_decisions.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -791,14 +791,14 @@
791791
- :who: mocsharp
792792
:why: Apache-2.0 (https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
793793
:versions:
794-
- 0.1.9
794+
- 0.1.11
795795
:when: 2022-08-16 23:06:21.051573547 Z
796796
- - :approve
797797
- Monai.Deploy.Messaging.RabbitMQ
798798
- :who: mocsharp
799799
:why: Apache-2.0 (https://github.com/Project-MONAI/monai-deploy-messaging/raw/main/LICENSE)
800800
:versions:
801-
- 0.1.9
801+
- 0.1.11
802802
:when: 2022-08-16 23:06:21.511789690 Z
803803
- - :approve
804804
- Monai.Deploy.Storage

docker-compose/docker-compose.yml

Lines changed: 45 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
version: "3.9"
1616
services:
1717
rabbitmq:
18-
image: rabbitmq:3-management
18+
image: rabbitmq:3.10-management
1919
hostname: rabbitmq
2020
ports:
2121
- 5672:5672
@@ -27,9 +27,10 @@ services:
2727
RABBITMQ_ERLANG_COOKIE: "SWQOKODSQALRPCLNMEQG"
2828
healthcheck:
2929
test: rabbitmq-diagnostics -q ping
30-
interval: 15s
30+
start_period: 10s
31+
interval: 5s
3132
timeout: 30s
32-
retries: 3
33+
retries: 5
3334
networks:
3435
- monaideploy
3536

@@ -48,34 +49,53 @@ services:
4849
MINIO_ROOT_PASSWORD: minioadmin
4950
healthcheck:
5051
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
51-
interval: 15s
52+
start_period: 10s
53+
interval: 5s
5254
timeout: 30s
53-
retries: 3
55+
retries: 5
5456
networks:
5557
- monaideploy
5658

57-
createbuckets:
58-
image: minio/mc
59+
mongodb:
60+
image: mongo:latest
5961
environment:
60-
MINIO_ROOT_USER: minioadmin
61-
MINIO_ROOT_PASSWORD: minioadmin
62-
BUCKET_NAME: monaideploy
63-
ENDPOINT: http://minio:9000
64-
depends_on:
65-
minio:
66-
condition: service_healthy
62+
MONGO_INITDB_ROOT_USERNAME: root
63+
MONGO_INITDB_ROOT_PASSWORD: rootpassword
64+
ports:
65+
- 27017:27017
66+
volumes:
67+
- ./.run/mongodb/:/data/db
6768
networks:
6869
- monaideploy
69-
entrypoint: >
70-
/bin/sh -c "
71-
until (/usr/bin/mc config host add myminio $$ENDPOINT $$MINIO_ROOT_USER $$MINIO_ROOT_PASSWORD) do echo '...waiting...' && sleep 1; done;
72-
/usr/bin/mc mb myminio/$$BUCKET_NAME;
73-
/usr/bin/mc policy set public myminio/$$BUCKET_NAME;
74-
/usr/bin/mc ls myminio;
75-
# exit 0
76-
"
70+
healthcheck:
71+
test: echo 'db.runCommand("ping").ok' | mongo localhost:27017/productiondb --quiet
72+
interval: 10s
73+
timeout: 10s
74+
retries: 5
75+
start_period: 40s
76+
77+
orthanc:
78+
image: osimis/orthanc:22.9.0
79+
hostname: orthanc
80+
volumes:
81+
- ./configs/orthanc.json:/etc/orthanc/orthanc.json
82+
- .run/orthanc:/var/lib/orthanc/db/
83+
ports:
84+
- "1114:1114"
85+
- "8089:8089"
86+
environment:
87+
VERBOSE_ENABLED: "true"
88+
networks:
89+
- monaideploy
90+
healthcheck:
91+
test: ["CMD", "/probes/test-aliveness.py"]
92+
start_period: 10s
93+
retries: 3
94+
interval: 15s
95+
timeout: 30s
7796

7897
elasticsearch:
98+
profiles: [ 'elk' ]
7999
image: docker.elastic.co/elasticsearch/elasticsearch:${ELASTIC_VERSION}
80100
hostname: elasticsearch
81101
volumes:
@@ -98,6 +118,7 @@ services:
98118
retries: 50
99119

100120
logstash:
121+
profiles: [ 'elk' ]
101122
image: docker.elastic.co/logstash/logstash:${ELASTIC_VERSION}
102123
volumes:
103124
- ./configs/logstash.yml:/usr/share/logstash/config/logstash.yml:ro,Z
@@ -120,6 +141,7 @@ services:
120141
- monaideploy
121142

122143
kibana:
144+
profiles: [ 'elk' ]
123145
image: docker.elastic.co/kibana/kibana:${ELASTIC_VERSION}
124146
volumes:
125147
- ./configs/kibana.yml:/usr/share/kibana/config/kibana.yml:ro,Z
@@ -139,6 +161,7 @@ services:
139161
retries: 120
140162

141163
kibana-setup:
164+
profiles: [ 'elk' ]
142165
image: curlimages/curl:latest
143166
volumes:
144167
- ./configs/kibana.ndjson:/usr/share/kibana.ndjson

0 commit comments

Comments
 (0)