From d73d08f850a492711b16bd371807e8eefa289250 Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 13:50:51 +0200 Subject: [PATCH 1/8] Install font before building docker image --- .github/workflows/publish.yaml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index b968e5a..0a9c768 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -41,6 +41,12 @@ jobs: type=semver,pattern={{version}} type=sha,enable=true,priority=100,prefix=sha-,suffix=,format=short + - name: Install Arial font + run: | + sudo apt-get update + sudo apt install ttf-mscorefonts-installer + sudo apt-get install -y ttf-mscorefonts-installer + - name: Build Docker image uses: docker/build-push-action@v6 with: @@ -48,12 +54,6 @@ jobs: push: false # Do not push at this stage tags: ${{ steps.meta.outputs.tags }} - - name: Install Arial font - run: | - sudo apt-get update - sudo apt-get install -y ttf-mscorefonts-installer - - - name: Push Docker image uses: docker/build-push-action@v6 with: From 3f8cb8cc111b8036e21bd64cda7f0ba13c1011e2 Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 13:52:13 +0200 Subject: [PATCH 2/8] Run `publish` on PR --- .github/workflows/publish.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 0a9c768..3eead93 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -4,6 +4,8 @@ on: workflow_dispatch: # This line adds the manual trigger push: branches: [ "main" ] + pull_request: + branches: [ "main" ] env: REGISTRY: ghcr.io From 10ea6518fbd8f7ae9dfab91548ba4a39fa52a27f Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:04:22 +0200 Subject: [PATCH 3/8] Revert to the old `build-push-action` --- .github/workflows/publish.yaml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 3eead93..714b702 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -4,8 +4,8 @@ on: workflow_dispatch: # This line adds the manual trigger push: branches: [ "main" ] - pull_request: - branches: [ "main" ] + pull_request: + branches: [ "main" ] env: REGISTRY: ghcr.io @@ -48,16 +48,17 @@ jobs: sudo apt-get update sudo apt install ttf-mscorefonts-installer sudo apt-get install -y ttf-mscorefonts-installer + sudo fc-cache -f - name: Build Docker image - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v5 with: context: . push: false # Do not push at this stage tags: ${{ steps.meta.outputs.tags }} - name: Push Docker image - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v5 with: context: . push: true From 7a5a8f82ce6d97487ac6d662655a8c1768b8f27c Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:07:12 +0200 Subject: [PATCH 4/8] Execute on PR --- .github/workflows/publish.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 714b702..182a3a4 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -4,8 +4,8 @@ on: workflow_dispatch: # This line adds the manual trigger push: branches: [ "main" ] - pull_request: - branches: [ "main" ] + pull_request: + branches: [ "main" ] env: REGISTRY: ghcr.io From 6714f88ed38d02973440fc7ad9681753ccb3e04e Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:33:23 +0200 Subject: [PATCH 5/8] Fix readme and the dockerfile --- .github/workflows/publish.yaml | 4 ++-- Dockerfile | 2 +- README.md | 13 +++++++++---- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index 182a3a4..abc8f17 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -51,14 +51,14 @@ jobs: sudo fc-cache -f - name: Build Docker image - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: false # Do not push at this stage tags: ${{ steps.meta.outputs.tags }} - name: Push Docker image - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true diff --git a/Dockerfile b/Dockerfile index 209ab52..bea7581 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM maven:3-eclipse-temurin-22 AS builder +FROM maven:3-eclipse-temurin-17 AS builder WORKDIR /app diff --git a/README.md b/README.md index 16505aa..806f4b2 100644 --- a/README.md +++ b/README.md @@ -4,17 +4,22 @@ | Badges | | |:----:|----| | **Fairness** | [![fair-software.eu](https://img.shields.io/badge/fair--software.eu-%E2%97%8F%20%20%E2%97%8F%20%20%E2%97%8F%20%20%E2%97%8F%20%20%E2%97%8F-green)](https://fair-software.eu) [![OpenSSF Best Practices](https://bestpractices.coreinfrastructure.org/projects/8082/badge)](https://www.bestpractices.dev/projects/8082) | -| **Packages and Releases** | [![Latest release](https://img.shields.io/github/release/sanctuuary/RESTAPE.svg)](https://github.com/sanctuuary/restape/releases/latest) [![Static Badge](https://img.shields.io/badge/RSD-RESTfulAPE-ape)](https://research-software-directory.org/software/restape) | +| **Packages and Releases** | [![Latest release](https://img.shields.io/github/release/sanctuuary/RESTAPE.svg)](https://github.com/sanctuuary/restape/releases/latest) [![Static Badge](https://img.shields.io/badge/RSD-RESTfulAPE-ape)](https://research-software-directory.org/software/restape) | + | **Build Status** | ![build](https://github.com/sanctuuary/RestAPE/actions/workflows/maven.yml/badge.svg) [![CodeQL](https://github.com/sanctuuary/restape/actions/workflows/codeql.yml/badge.svg)](https://github.com/sanctuuary/restape/actions/workflows/codeql.yml) | | **Documentation** | [![Documentation Status](https://readthedocs.org/projects/ape-framework/badge/?version=latest)](https://ape-framework.readthedocs.io/en/latest/docs/restful-ape/introduction.html) | | **DOI** | [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.10048236.svg)](https://doi.org/10.5281/zenodo.10048236) | | **License** | [![GitHub license](https://img.shields.io/github/license/sanctuuary/RESTAPE)](https://github.com/sanctuuary/RESTAPE/blob/master/LICENSE) | -A RESTful API for the APE library (RESTful APE) provides a way for users to interact with APE's automated pipeline exploration capabilities through HTTP requests. APE is a command line tool and Java API that automates the exploration of possible computational pipelines from large collections of computational tools. +The RESTful API for the APE library (RESTful APE) allows users to interact with APE's automated pipeline exploration features through HTTP requests. APE automates the exploration of computational pipelines from large collections of computational tools. + +Users can submit pipeline exploration requests to the APE server and receive results in JSON format. This interface allows interaction with APE via web browsers or any HTTP client and can be integrated into other applications. + +In addition to APE's core feature of automated workflow composition, the API performs design-time benchmarking of workflows by aggregating tool-specific information such as licenses and citations for better workflow comparison. -The RESTful API allows users to submit requests to the APE server for pipeline exploration, which returns results in a standard format such as JSON or XML. Users can interact with APE through a web browser or any other HTTP client, and the API can be integrated into other applications for seamless pipeline exploration. +RESTful APE is packaged in a [Docker image](https://github.com/sanctuuary/restape/pkgs/container/restape). -Overall, the RESTful API for APE provides a powerful and flexible way for users to leverage APE's capabilities in their scientific workflows. +Overall, the RESTful API for APE provides a flexible way to leverage APE's capabilities in scientific workflows. ## Development From 965b771f61c24cfcd1a4a2851156b7aa56171e59 Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:41:16 +0200 Subject: [PATCH 6/8] Update eclipse image from 17 to 22 --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index bea7581..cd288b9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM maven:3-eclipse-temurin-17 AS builder +FROM maven:3-eclipse-temurin-22 AS builder WORKDIR /app @@ -13,7 +13,7 @@ RUN --mount=type=cache,target=/root/.m2 \ mvn -f pom.xml clean package -FROM eclipse-temurin:17-jre-jammy +FROM eclipse-temurin:22-jre-jammy WORKDIR /app COPY --from=builder /app/target/*.jar /app/runner.jar From 63452cb0c9dd243925d7d69cd3e92f89c5d84613 Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:43:50 +0200 Subject: [PATCH 7/8] Change back to java 17 --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index cd288b9..bea7581 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM maven:3-eclipse-temurin-22 AS builder +FROM maven:3-eclipse-temurin-17 AS builder WORKDIR /app @@ -13,7 +13,7 @@ RUN --mount=type=cache,target=/root/.m2 \ mvn -f pom.xml clean package -FROM eclipse-temurin:22-jre-jammy +FROM eclipse-temurin:17-jre-jammy WORKDIR /app COPY --from=builder /app/target/*.jar /app/runner.jar From ba992c5397f3733db656cba7ef554278a18a4710 Mon Sep 17 00:00:00 2001 From: Vedran Kasalica Date: Tue, 30 Jul 2024 14:44:30 +0200 Subject: [PATCH 8/8] Update `publish` not to trigger on PR --- .github/workflows/publish.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index abc8f17..09c2134 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -4,8 +4,6 @@ on: workflow_dispatch: # This line adds the manual trigger push: branches: [ "main" ] - pull_request: - branches: [ "main" ] env: REGISTRY: ghcr.io