1. Ставим из пакетов Debian Orthanc, к нему SQL
apt install orthanc orthanc-mysql orthanc-dicomweb mariadb-server nginx gnupg wget mc
2. Для установки вебвьюверов добавляем репозитории с Ортанка, ставим вьюверы.
wget -qO - https://debian.orthanc-labs.com/archive.key | apt-key add -
deb https://debian.orthanc-labs.com/ bookworm main
deb https://debian.orthanc-labs.com/ bookworm main
apt-add-repository "deb https://debian.orthanc-labs.com/ `grep VERSION_CODENAME /etc/os-release | cut -d'=' -f 2` main"
apt install orthanc-stone-webviewer orthanc-ohif
3. Настраиваем Orthanc
3.1 /etc/orthanc/credentials.json
"RegisteredUsers" : {
// "alice" : "alicePassword"
"pacs": "pacs",
"orthanc" : "orthanc"
}
3.2 /etc/orthanc/mysql.json
БД надо создать, но пустую, таблицы orthanc сам создаст.
"MySQL" : {
// Enable the use of MySQL to store the Orthanc index?
"EnableIndex" : true,
// Enable the use of MySQL to store the DICOM files?
"EnableStorage" : false,
// Parameters of the MySQL database
"Host" : "localhost",
"Port" : 3306,
"Database" : "orthanc",
"Username" : "orthanc",
"UnixSocket" : "/var/run/mysqld/mysqld.sock",
"Password" : "orthanc",
3.3. /etc/orthanc/orthanc.json Перекидываем хранилище и БД (БД - не обязательно) на большую FS
// "StorageDirectory" : "/var/lib/orthanc/db-v6",
"StorageDirectory" : "/data/dicom/db",
// "IndexDirectory" : "/var/lib/orthanc/db-v6",
"IndexDirectory" : "/data/dicom/db",
3.4. /etc/orthanc/orthanc.json Включаем https, сертификат кладем в /etc/orthanc/
// Whether remote hosts can connect to the HTTP server
"RemoteAccessAllowed" : true,
// Whether or not SSL is enabled
"SslEnabled" : true,
// Path to the SSL certificate used by the HTTP server. The file
// must be stored in the PEM format, and must contain both the
// certificate and the private key. This option is only meaningful
// if "SslEnabled" is true.
"SslCertificate" : "certificate.pem",
3.5. /etc/orthanc/orthanc.json добавляем модальности
"DicomModalities" : {
"orthanc-s3" : ["orthanc","192.168.88.2", 4242 ],
"workstation" : ["workstation","192.168.88.3", 11112 ],
...
3.6. /etc/orthanc/dicomweb.json добавляем себя в dicomweb
"DicomWeb" : {
"Enable" : true, // Whether DICOMweb support is enabled
...
"SeriesMetadata" : "Full", // Add comma!
"Servers" : {
"self" : [ "https://pacs.local:8042/dicom-web/", "pacs", "pacs" ]
}
4. /etc/nginx/sites-enabled/default Включаем nginx, включаем redirect с 443 и 80 на 8042.
server {
listen 80 default_server;
listen 443 ssl default_server;
include snippets/snakeoil.conf;
#root /var/www/html;
return 301 https://pacs.local:8042;
5. /etc/nginx/snippets/snakeoil.conf Настраиваем на nginx сертификаты (формат сертификата и ключа другой)
ssl_certificate /etc/orthanc/pacs.crt;
ssl_certificate_key /etc/orthanc/pacs.key;