Skip to content

Commit

Permalink
[TEST] Analysing Orthanc
Browse files Browse the repository at this point in the history
  • Loading branch information
VaishSiddharth committed Oct 24, 2024
1 parent b12758c commit f7c858c
Show file tree
Hide file tree
Showing 4 changed files with 1,100 additions and 0 deletions.
36 changes: 36 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Use the base Orthanc plugins image
FROM jodogne/orthanc-plugins:latest

RUN apt-get update && apt-get install -y openjdk-17-jdk cmake build-essential python3 unzip libjsoncpp-dev \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64

WORKDIR /home/root/
RUN wget -qO- https://orthanc.uclouvain.be/downloads/sources/orthanc-java/OrthancJava-1.0.tar.gz | tar xvz

WORKDIR /home/root/OrthancJava-1.0
RUN mkdir BuildPlugin && \
cd BuildPlugin && \
cmake ../Plugin -DCMAKE_BUILD_TYPE=Release && \
make

WORKDIR /home/root/OrthancJava-1.0
RUN mkdir BuildJavaSDK && \
cd BuildJavaSDK && \
cmake ../JavaSDK && \
make

WORKDIR /home/root/
RUN wget https://orthanc.uclouvain.be/downloads/cross-platform/orthanc-java/mainline/OrthancFHIR.jar

COPY java/HelloWorld.java /home/root/java/
WORKDIR /home/root/java/
RUN javac -cp /home/root/OrthancJava-1.0/BuildJavaSDK/OrthancJavaSDK.jar HelloWorld.java

# Expose Orthanc default port
EXPOSE 4242 8042

ENV LD_PRELOAD=/usr/lib/jvm/java-17-openjdk-amd64/lib/server/libjvm.so
ENTRYPOINT ["/usr/local/sbin/Orthanc"]
57 changes: 57 additions & 0 deletions docker-compose-orthanc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
version: "3.8"

services:
orthanc:
command: /run/secrets/
secrets:
- orthanc.json
build:
context: .
dockerfile: Dockerfile
restart: always
environment:
- ORTHANC_NAME=${ORTHANC_NAME}
- ORTHANC_AUTHENTICATION=keycloak
- KEYCLOAK_REALM=orthanc
- KEYCLOAK_CLIENT_ID=orthanc
volumes:
- orthanc-db:/var/lib/orthanc/db
networks:
- ozone
- web
ports:
- "8888:8042"
# depends_on:
# env-substitution:
# condition: service_completed_successfully

# keycloak:
# image: orthancteam/orthanc-keycloak:latest
# restart: always
# ports:
# - "8080:8080"
# environment:
# - ORTHANC__USER__NAME=orthanc
# - ORTHANC__USER__PASSWORD=orthanc
# - KC_DB="postgresql"
# - KC_DB_URL="jdbc:postgresql://postgres:5432/keycloak"
# - KC_DB_USERNAME="orthanc"
# - KC_DB_PASSWORD="orthanc"
# networks:
# - ozone
# - web

# env-substitution:
# environment:
# - ORTHANC_PUBLIC_URL=http://${ORTHANC_HOSTNAME}

secrets:
orthanc.json:
file: orthanc.json

networks:
ozone:
web:

volumes:
orthanc-db:
Empty file added java/HelloWorld.java
Empty file.
Loading

0 comments on commit f7c858c

Please sign in to comment.