Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions deploy/helm/Gateway-local.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Copyright 2022 MONAI Consortium
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
replicaCount: 1

image:
repository: registry.gitlab.com/answerdigital/londonai/aide/workflow-manager-images/infomatics-gateway
pullPolicy: IfNotPresent
tag: 2022-08-01

enviromentVariables:
InformaticsGateway__messaging__publisherSettings__endpoint: "rabbitmq-monai"
InformaticsGateway__messaging__publisherSettings__username: "admin"
InformaticsGateway__messaging__publisherSettings__password: "admin"
InformaticsGateway__messaging__subscriberSettings__endpoint: "rabbitmq-monai"
InformaticsGateway__messaging__subscriberSettings__username: "admin"
InformaticsGateway__messaging__subscriberSettings__password: "admin"
InformaticsGateway__storage__settings__endpoint: "minio.monai:9000"
InformaticsGateway__storage__settings__accessKey: "admin"
InformaticsGateway__storage__settings__accessToken: "password"
InformaticsGateway__dicom__scp__rejectUnknownSources: false


service:
type: ClusterIP
port: 5000
port2: 104



15 changes: 15 additions & 0 deletions deploy/helm/Gateway.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,23 @@ enviromentVariables:
InformaticsGateway__storage__settings__endpoint: "minio.monai:9000"
InformaticsGateway__storage__settings__accessKey: "rootminio"
InformaticsGateway__storage__settings__accessToken: "rootminio"
InformaticsGateway__dicom__scp__rejectUnknownSources: false


service:
type: ClusterIP
port: 5000
port2: 104


volumes:
name: gateway-storage
claimName: gateway-storage-claim
namespace: monai
storage: 1Gi
path: /efs_data/monai/gateway # path on the host

volumeMounts:
mountPath: "/database"
name: gateway-storage

19 changes: 15 additions & 4 deletions deploy/helm/MWM.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,23 @@ enviromentVariables:
WorkflowManager__storage__settings__executableLocation: "mc"
WorkflowManager__messaging__publisherSettings__endpoint: "rabbitmq.monai"
WorkflowManager__messaging__subscriberSettings__endpoint: "rabbitmq.monai"
WorkflowManager__messaging__publisherSettings__username: "monaideploy"
WorkflowManager__messaging__subscriberSettings__username: "monaideploy"
WorkflowManager__messaging__subscriberSettings__password: "monaideploy"
WorkflowManager__messaging__publisherSettings__password: "monaideploy"
WorkloadManagerDatabase__ConnectionString: "mongodb://root:rootpassword@mongo-monai.monai:27017"

enviromentVariablesFromSecrets:
secrets:
- name: WorkflowManager__messaging__subscriberSettings__username
secretName: rabbit-secret-master
secretKey: username
- name: WorkflowManager__messaging__subscriberSettings__password
secretName: rabbit-secret-master
secretKey: password
- name: WorkflowManager__messaging__publisherSettings__username
secretName: rabbit-secret-master
secretKey: username
- name: WorkflowManager__messaging__publisherSettings__password
secretName: rabbit-secret-master
secretKey: password

service:
type: ClusterIP
port: 5000
Expand Down
42 changes: 42 additions & 0 deletions deploy/helm/minio-local.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@

# Copyright 2022 MONAI Consortium
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

replicaCount: 1

# image:
# repository: minio/minio
# pullPolicy: IfNotPresent
# tag: latest
# command:
# - "/bin/sh"
# - "-ce"
# - "/usr/bin/docker-entrypoint.sh minio server /data"

enviromentVariables:
MINIO_ROOT_USER: admin
MINIO_ROOT_PASSWORD: password

service:
type: NodePort
port: 9000
nodeport: 30090
port2: 9001
nodeport2: 30091
selector:
app: minio




1 change: 0 additions & 1 deletion deploy/helm/minio.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ replicaCount: 1
enviromentVariables:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
WorkflowManager__storage__settings__endpoint: "minio:9000"

service:
type: NodePort
Expand Down
2 changes: 1 addition & 1 deletion deploy/helm/mongo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ volumes:
claimName: mongo-storage-claim
namespace: monai
storage: 5Gi
path: /var/local/mongodata # path on the host
path: /efs_data/monai/mongodata # path on the host

volumeMounts:
mountPath: "/data/db"
Expand Down
37 changes: 37 additions & 0 deletions deploy/helm/rabbitmq-local.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Copyright 2022 MONAI Consortium
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

replicaCount: 1

image:
repository: rabbitmq
pullPolicy: IfNotPresent
tag: 3.8.18-management

enviromentVariables:
RABBITMQ_ERLANG_COOKIE: "SWQOKODSQALRPCLNMEQG"
RABBITMQ_DEFAULT_USER: "admin"
RABBITMQ_DEFAULT_PASS: "admin"
RABBITMQ_DEFAULT_VHOST: "monaideploy"


service:
type: NodePort
port: 5672
nodeport: 30072
port2: 15672
nodeport2: 30672



4 changes: 2 additions & 2 deletions deploy/helm/rabbitmq.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ image:

enviromentVariables:
RABBITMQ_ERLANG_COOKIE: "SWQOKODSQALRPCLNMEQG"
RABBITMQ_DEFAULT_USER: "admin"
RABBITMQ_DEFAULT_PASS: "admin"
RABBITMQ_DEFAULT_USER: "monaideploy"
RABBITMQ_DEFAULT_PASS: "monaideploy"
RABBITMQ_DEFAULT_VHOST: "monaideploy"


Expand Down
13 changes: 11 additions & 2 deletions deploy/helm/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,17 @@ spec:
env:
{{- range $name, $value := .Values.enviromentVariables }}
- name: {{ $name }}
value: {{ $value }}
{{- end }}
value: {{ $value | quote }}
{{- end }}

{{- range .Values.enviromentVariablesFromSecrets.secrets }}
- name: {{ .name }}
valueFrom:
secretKeyRef:
name: {{ .secretName}}
key: {{ .secretKey}}
{{- end }}

{{- end }}
ports:
- name: http
Expand Down
17 changes: 15 additions & 2 deletions guidelines/mwm-developer-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ save the file, now `http://minio:9000` will route to you local machine
install Helm 3 https://helm.sh/docs/intro/install/
from a bash terminal in the root folder of the project
- `helm upgrade -i -n argo -f deploy/helm/mongo-local.yaml mongo deploy/helm`
- `helm upgrade -i -n argo -f deploy/helm/rabbitmq.yaml rabbit deploy/helm`
- `helm upgrade -i -n argo -f deploy/helm/rabbitmq-local.yaml rabbit deploy/helm`

### running in VisualStudio
Now assuming your launchSettings has the line
Expand All @@ -74,7 +74,7 @@ Open the post/workflows tab and click `try it out`, paste in the following to th
"version": "1.0.0",
"description": "Attempt at making a workflow",
"informatics_gateway": {
"ae_title": "MYAET",
"ae_title": "MonaiSCU",
"data_origins": [
"MY_SCANNER"
],
Expand Down Expand Up @@ -212,4 +212,17 @@ then
- `mc ls --recursive mwm/bucket1` list all files in bucket


## Informatics Gateway
Although it has its own repo and is separate from the Workflow Manager, I have included a Helm file for it in here, its called Gateway and to deploy it use.
`helm -n monai upgrade -i -f deploy/helm/Gateway-local.yaml mig helm` Obviously change the namespace, name and path to suit.

Once deployed
- exec into the running container ie `kubectl -n monai exec -it mig-monai-797f584bf9-9tw8j -- bash`
- install curl `apt update;apy install curl -y`
- add the default AETitle `curl -H 'Content-Type: application/json-patch+json' -d '{"aeTitle": "MonaiSCU","name": "Monai WFM"}' mig-monai:5000/config/ae`
- `exit`

The Informatics Gateway is now set up to recieve and pass on data from the PACS or Orthanc servers

if using orthanc something like this `"DicomModalities": {"monai" : [ "MonaiSCU", "mig-monai.monai", 104 ]}` would need to be in its config file.