From 524879333ff46908913de9c5c6166083a1972b2d Mon Sep 17 00:00:00 2001 From: manimaarans Date: Wed, 15 Nov 2023 17:47:03 +0530 Subject: [PATCH] deploy commit --- .github/workflows/build_publish_cdss.yml | 46 ++++++++++++++++++++++++ package/docker/cdss/Dockerfile | 10 ++++++ 2 files changed, 56 insertions(+) create mode 100644 .github/workflows/build_publish_cdss.yml create mode 100644 package/docker/cdss/Dockerfile diff --git a/.github/workflows/build_publish_cdss.yml b/.github/workflows/build_publish_cdss.yml new file mode 100644 index 0000000..7565409 --- /dev/null +++ b/.github/workflows/build_publish_cdss.yml @@ -0,0 +1,46 @@ +name: Build and Publish FHIR CDS Service +on: + push: + branches: + - main + - BS-290-deploy + paths-ignore: + - "**.md" + workflow_dispatch: + +jobs: + build-publish-docker: + name: Build & Publish Docker Image + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up JDK 17 + uses: actions/setup-java@v3 + with: + distribution: corretto + java-version: 17 + + - name: Build with Maven + run: mvn clean -U package -DskipTests + + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Login to DockerHub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKER_HUB_USERNAME }} + password: ${{ secrets.DOCKER_HUB_TOKEN }} + - name: Docker Build and push + uses: docker/build-push-action@v3 + with: + context: . + platforms: linux/amd64,linux/arm64 + file: package/docker/cdss/Dockerfile + push: true + tags: bahmni/cdss-reference:snomed-${{ github.run_number }},bahmni/cdss-reference:latest diff --git a/package/docker/cdss/Dockerfile b/package/docker/cdss/Dockerfile new file mode 100644 index 0000000..8fa755a --- /dev/null +++ b/package/docker/cdss/Dockerfile @@ -0,0 +1,10 @@ +FROM eclipse-temurin:17.0.6_10-jre + +ARG JAR_FILE=target/*.jar +COPY ${JAR_FILE} snomed-fhir-cds-service.jar +COPY CDS_Medication-Condition_Cards.xlsx CDS_Medication-Condition_Cards.xlsx +COPY CDS_Medication-Medication_Cards.tsv CDS_Medication-Medication_Cards.tsv +COPY Snomed_Substance_DDDs.tsv Snomed_Substance_DDDs.tsv +COPY ATC_Route_Of_Administration_Snomed_DoseForm_Map.tsv ATC_Route_Of_Administration_Snomed_DoseForm_Map.tsv + +ENTRYPOINT exec java $JAVA_OPTS -jar /snomed-fhir-cds-service.jar \ No newline at end of file