imaging-viewer .env file


Overview

The imaging-viewer component relies on environment variables/options defined in a .env file located here:

/opt/cast/installation/imaging-viewer/

These variables/options configure service discovery, APIs, AI Manager, ETL, Server, Neo4j, and Docker images. Below is a detailed explanation of each option.

Eureka (Service Discovery)

VariableDefault/ExampleDescription
SERVICE_HOSTFQDNHostname or IP address where “imaging-viewer” services can be discovered.
EUREKA_HOSTFQDNHost address for the Eureka server.
EUREKA_PORT8098Port where Eureka is running.

CAST Imaging APIs

VariableDefault/ExampleDescription
IMAGING_APIS_PORT8070Port for CAST Imaging API service.
API_KEY(empty)API key for authentication (set in production).
SOURCE_CODE_SERVICE_TOKEN(empty)Token for connecting to source code service.
SOURCE_CODE_SERVICE_ENDPOINT(empty)URL/endpoint for source code service.
TRUSTED_PROXIES(empty)Comma-separated list of trusted proxy IPs.
ACCESS_CONTROL_ALLOW_ORIGIN(empty)Allowed CORS origin(s).
ACCESS_CONTROL_ALLOW_METHODS(empty)Allowed HTTP methods for CORS.
ACCESS_CONTROL_ALLOW_HEADERS(empty)Allowed request headers for CORS.

CAST Imaging AI Manager

VariableDefault/ExampleDescription
AIMANAGER_PORT8082Port for AI Manager service.

CAST Imaging ETL

VariableDefault/ExampleDescription
ETL_PORT9001Port for ETL service.
WORKER_POOL_SIZE4Allowed number of parallel threads (imports)
NEO4J_IMPORT_BATCH_SIZE1000Batch size for importing data into Neo4j.

CAST Imaging Service (Backend + Frontend)

VariableDefault/ExampleDescription
SERVER_PORT9000Port for CAST Imaging Viewer backend service.
FE_PORT8083Port for CAST Imaging Viewer frontend UI.
APP_CONTEXT(empty)Optional application context path (e.g., /cast).

CAST Imaging Neo4j Database

VariableDefault/ExampleDescription
NEO4J_HTTP_PORT7474Neo4j HTTP port (browser access).
NEO4J_BOLT_PORT7687Neo4j Bolt driver port (used by services).
NEO4J_server_memory_heap_initial__size12GInitial heap size allocated for Neo4j (equivalent to server.memory.heap.initial_size available in the neo4j.conf file). Note the double underscore in use between initial and size. See also Customizing Neo4j.
Available in ≥ 3.5.4-funcrel
NEO4J_server_memory_heap_max__size12GMax heap size allocated for Neo4j (equivalent to server.memory.heap.max_size available in the neo4j.conf file). Note the double underscore in use between max and size. See also Customizing Neo4j.
Available in ≥ 3.5.4-funcrel
NEO4J_dbms_memory_transaction_total_max12GMaximum total memory all concurrent transactions can consume, preventing OutOfMemory errors by capping transaction resource usage. Equivalent to dbms.memory.transaction.total.max available in the neo4j.conf. See also Customizing Neo4j.
Available in ≥ 3.5.4-funcrel

Note that the following variables were available only in 3.5.0-funcrel - 3.5.4-funcrel:

VariableDefault/ExampleDescription
NEO4J_HEAP_SIZE12GHeap size allocated for Neo4j. This option sets both the server.memory.heap.initial_size and server.memory.heap.max_size options available in the neo4j.conf to the same value.
NEO4J_TRANSACTION_MEMORY10GMaximum total memory all concurrent transactions can consume, preventing OutOfMemory errors by capping transaction resource usage. Equivalent to dbms.memory.transaction.total.max available in the neo4j.conf.

Docker Images & Repository

VariableDefault/ExampleDescription
ETL_IMAGE_TAGlatestTag for ETL image.
SERVER_IMAGE_TAGlatestTag for Server image.
NEO4J_IMAGE_TAGlatestTag for Neo4j image.
AIMANAGER_IMAGE_TAGlatestTag for AI Manager image.
IMAGING_API_IMAGE_TAGlatestTag for Imaging API image.
DOCKER_REPOcastimagingDocker repository name.

Common Settings

VariableDefault/ExampleDescription
QUERY_TIMEOUT60Query timeout (seconds).
LOG_LEVELdebugLogging level (info or debug).
TIME_ZONEUTCDefault time zone for services.
NEO4J_BOLT_ENDPOINTbolt://neo4j:7687Neo4j Bolt endpoint (must align with NEO4J_BOLT_PORT).
PODMAN_ENVfalseSpecifies whether Podman is the target installation environment.