Skip to main content

Local Development Setup

Requirements​

The project currently specifies:

  • Node ^22.20.x
  • Yarn 4.13.0

Confirm these are still the intended known-good development versions before finalizing the project documentation.

Install and Run​

Install dependencies:

yarn install

Start the development server:

yarn start

The Vite development server currently runs at:

http://localhost:3000

The project also provides build, test, and lint scripts through package.json.

Local Environment​

For local development, copy:

.env.example

to:

.env.local

The default local configuration routes DICOMweb requests through /dicom-web to local Orthanc at http://localhost:8042.

Primary configuration:

VITE_DICOMWEB_BASE_URL=/dicom-web
VITE_DICOMWEB_PROXY_BASE=/dicom-web
VITE_DICOMWEB_PROXY_TARGET=http://localhost:8042
VITE_PACS_LABEL=Local Orthanc

Restart yarn start after changing the environment configuration.

Additional test-server, authentication, and PACS tuning options are documented in .env.example.

Local Orthanc Setup

Local development uses Orthanc as the DICOMweb/PACS server.

Prerequisites​

  • Docker Desktop
  • Git Bash for the currently documented Windows workflow
  • A local orthanc folder

orthanc.json​

Create orthanc.json in the Orthanc folder:

{
"Name": "Local Orthanc",
"StorageDirectory": "/var/lib/orthanc/db",
"IndexDirectory": "/var/lib/orthanc/db",
"HttpPort": 8042,
"DicomPort": 4242,
"AuthenticationEnabled": false,
"RegisteredUsers": {},
"RemoteAccessAllowed": true,
"Plugins": [
"/usr/share/orthanc/plugins"
],
"DicomWeb": {
"Enable": true,
"Root": "/dicom-web/"
}
}

The configuration uses:

  • HTTP interface: port 8042
  • DICOM: port 4242
  • DICOMweb: /dicom-web/

Create an orthanc-data/ directory in the same folder for persistent local data.

Start Orthanc​

Open Git Bash in the Orthanc folder and run:

MSYS_NO_PATHCONV=1 docker run --rm \
-p 8042:8042 \
-p 4242:4242 \
-v "$(pwd)/orthanc.json:/etc/orthanc/orthanc.json:ro" \
-v "$(pwd)/orthanc-data:/var/lib/orthanc/db" \
orthancteam/orthanc:latest /etc/orthanc/orthanc.json

Orthanc should then be accessible at:

http://localhost:8042

The current configuration has authentication disabled and is intended for local development only.

DICOMweb / PACS Flow

Development data flow:

Browser → Vite Proxy → DICOMweb PACS

The UI requests /dicom-web/*, and Vite forwards those requests to the configured PACS target.

Security Note​

All VITE_ environment variables are bundled client-side and visible to users.

Long-lived secrets, PACS passwords, or privileged credentials should not be stored in them.