From 0b3695b4b76364b1b2ae7159846985d54e1bf64b Mon Sep 17 00:00:00 2001 From: Nisha Sharma Date: Thu, 13 Aug 2026 12:52:58 +0200 Subject: [PATCH 1/2] build: update prod build workflow to build image with release tag (#129) * build: update prod build workflow to build image with release tag * build: update prod build workflow to create and push docker image with release tag --- .github/workflows/prod-build.yml | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/workflows/prod-build.yml b/.github/workflows/prod-build.yml index 62fb832..13c6ed8 100644 --- a/.github/workflows/prod-build.yml +++ b/.github/workflows/prod-build.yml @@ -1,8 +1,8 @@ # This workflow will perform following actions when code is pushed to the main branch: # - Run tests and linting checks (can be enabled via needs: test_and_lint) -# - Build and push nmrKit Docker image with layer caching for faster builds +# - Build and push nmrKit Docker image with latest and release-version tags # - Conditionally build nmr-cli image only if files in app/scripts/nmr-cli/ changed -# - Push images to Docker Hub under namespace nfdi4chem with latest tag +# - Push images to Docker Hub under namespace nfdi4chem with latest tags (plus release-version tags) # - Prevent redundant builds using concurrency control # # Maintainers: @@ -93,6 +93,14 @@ jobs: nmr-cli: - 'app/scripts/nmr-cli/**' + # Fetch the latest GitHub release tag for versioned Docker tags + - name: Get latest release version + id: release_version + uses: pozetroninc/github-action-get-latest-release@v0.8.0 + with: + repository: ${{ github.repository }} + token: ${{ secrets.GITHUB_TOKEN }} + # Build main nmrKit image with registry caching for faster builds - name: Build and push nmrKit Docker image uses: docker/build-push-action@v6 @@ -100,8 +108,10 @@ jobs: context: . file: ./Dockerfile push: true - build-args: RELEASE_VERSION=${{ env.RELEASE_TAG }} - tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMRKIT_REPOSITORY_NAME }}:${{ env.RELEASE_TAG }} + build-args: RELEASE_VERSION=${{ steps.release_version.outputs.release }} + tags: | + ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMRKIT_REPOSITORY_NAME }}:${{ env.RELEASE_TAG }} + ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMRKIT_REPOSITORY_NAME }}:${{ steps.release_version.outputs.release }} cache-from: type=registry,ref=${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMRKIT_REPOSITORY_NAME }}:buildcache cache-to: type=registry,ref=${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMRKIT_REPOSITORY_NAME }}:buildcache,mode=max @@ -113,7 +123,9 @@ jobs: context: ./app/scripts/nmr-cli/ file: ./app/scripts/nmr-cli/Dockerfile push: true - build-args: RELEASE_VERSION=${{ env.RELEASE_TAG }} - tags: ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMR_CLI_REPOSITORY_NAME }}:${{ env.RELEASE_TAG }} + build-args: RELEASE_VERSION=${{ steps.release_version.outputs.release }} + tags: | + ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMR_CLI_REPOSITORY_NAME }}:${{ env.RELEASE_TAG }} + ${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMR_CLI_REPOSITORY_NAME }}:${{ steps.release_version.outputs.release }} cache-from: type=registry,ref=${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMR_CLI_REPOSITORY_NAME }}:buildcache cache-to: type=registry,ref=${{ env.REPOSITORY_NAMESPACE }}/${{ env.NMR_CLI_REPOSITORY_NAME }}:buildcache,mode=max From 5fd070565f86ebc3430045324bfdf2b21bbf4bf9 Mon Sep 17 00:00:00 2001 From: Nisha Sharma Date: Thu, 13 Aug 2026 13:31:20 +0200 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20Increase=20memory=20limit=20for=20No?= =?UTF-8?q?de.js=20in=20Docker=20containers=20to=20handle=E2=80=A6=20(#132?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix: Increase memory limit for Node.js in Docker containers to handle large 2D spectra * max-old-space-size --- app/scripts/nmr-cli/Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/scripts/nmr-cli/Dockerfile b/app/scripts/nmr-cli/Dockerfile index dc94d69..2e38276 100644 --- a/app/scripts/nmr-cli/Dockerfile +++ b/app/scripts/nmr-cli/Dockerfile @@ -14,6 +14,10 @@ WORKDIR /app ENV BASE_NMRIUM_URL=https://nmriumdev.nmrxiv.org/ ENV NMR_PREDICTION_URL=https://nmrshiftdb.nmr.uni-koeln.de/NmrshiftdbServlet/nmrshiftdbaction/quickcheck +# Override at runtime with: docker run -e NODE_OPTIONS="--max-old-space-size=" ... +ARG NODE_MAX_OLD_SPACE_SIZE=12288 +ENV NODE_OPTIONS=--max-old-space-size=${NODE_MAX_OLD_SPACE_SIZE} + # Install Java (OpenJDK 17 for Ubuntu Noble) RUN apt-get update && \ apt-get install -y --no-install-recommends openjdk-17-jre && \