From f401645dd12ae82f1a85b39a5caf6043272aabaa Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 04:28:08 +0000 Subject: [PATCH 01/10] Update all workflows to include inputs that allow to specify draft (marked and deployed to development instead of production) and to select building on a specific Medley release (as specified by the tag from a specific Github release in the Medley repo). --- .../workflows/buildAndDeployMedleyDocker.yml | 31 +++++++++-- .github/workflows/buildMedleyDocker.yml | 52 +++++++++++++++---- .github/workflows/deployMedleyDocker.yml | 17 +++++- 3 files changed, 84 insertions(+), 16 deletions(-) diff --git a/.github/workflows/buildAndDeployMedleyDocker.yml b/.github/workflows/buildAndDeployMedleyDocker.yml index a810dac8..df4b45a1 100644 --- a/.github/workflows/buildAndDeployMedleyDocker.yml +++ b/.github/workflows/buildAndDeployMedleyDocker.yml @@ -14,6 +14,14 @@ name: 'Build and Deploy Online-Medley Docker Image' on: workflow_dispatch: inputs: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false + github_release_tag: + description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + type: string + default: 'Latest' platform: type: choice options: @@ -27,11 +35,21 @@ on: OIO_SSH_KEY: required: true inputs: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false + required: false + github_release_tag: + description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + type: string + default: 'Latest' + required: false platform: - description: "linux/amd64 or linux/arm64" - type: string - default: 'linux/amd64' - required: false + description: "linux/amd64 or linux/arm64" + type: string + default: 'linux/amd64' + required: false defaults: run: @@ -41,12 +59,17 @@ jobs: build: uses: ./.github/workflows/buildMedleyDocker.yml with: + draft: ${{ inputs.draft }} + github.release.tag: ${{ inputs.github.release.tag }} platform: ${{ inputs.platform }} secrets: CCRYPT_KEY: ${{ secrets.CCRYPT_KEY }} deploy: needs: build uses: ./.github/workflows/deployMedleyDocker.yml + with: + draft: ${{ inputs.draft }} + github.release.tag: ${{ inputs.github.release.tag }} secrets: OIO_SSH_KEY: ${{ secrets.OIO_SSH_KEY }} diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index 265c36b6..3c64f19f 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -19,6 +19,14 @@ name: 'Build/Push Online-Medley Docker Image' on: workflow_dispatch: inputs: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false + github_release_tag: + description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + type: string + default: 'Latest' platform: type: choice options: @@ -30,6 +38,16 @@ on: CCRYPT_KEY: required: true inputs: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false + required: false + github_release_tag: + description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + type: string + default: 'Latest' + required: false platform: description: "linux/amd64 or linux/arm64" type: string @@ -47,7 +65,7 @@ jobs: steps: # Checkout the actions for this repo_owner - name: Checkout Actions - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: repository: ${{ github.repository_owner }}/.github path: ./Actions_${{ github.sha }} @@ -56,7 +74,7 @@ jobs: # Fetch cached LFS files - name: Cache LFS files id: cache-lfs - uses: actions/cache@v4 + uses: actions/cache@v5 with: path: | docker_medley/filebrowser/filebrowser @@ -71,7 +89,7 @@ jobs: # Checkout latest commit - name: Checkout Online code - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: lfs: ${{ steps.cache-lfs.outputs.cache-hit != 'true' }} @@ -103,9 +121,16 @@ jobs: - name: Get info from latest Medley image id: release_info run: | + if [ "${{ inputs.github_release_tag }}" = "Latest" ] || [ "${{ inputs.github_release_tag }}" = "latest" ] + then + DOCKER_TAG=latest + else + DOCKER_TAG="${{ inputs.github_release_tag }}" + DOCKER_TAG="${DOCKER_TAG##medley-}" + endif DOCKER_NAMESPACE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]') echo "docker_namespace=${DOCKER_NAMESPACE}" >> $GITHUB_OUTPUT - docker pull ${DOCKER_NAMESPACE}/medley:latest + docker pull "${DOCKER_NAMESPACE}/medley:${DOCKER_TAG}" RELEASE_INFO=$(docker run --entrypoint /bin/bash ${DOCKER_NAMESPACE}/medley:latest -c "echo \${MAIKO_RELEASE}::::\${MEDLEY_RELEASE}") MAIKO_RELEASE=${RELEASE_INFO%::::*} MEDLEY_RELEASE=${RELEASE_INFO#*::::} @@ -116,7 +141,7 @@ jobs: # Checkout the latest Notecards commit - name: Checkout Notecards - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: repository: "${{ github.repository_owner }}/notecards" path: "./docker_medley/notecards" @@ -141,26 +166,31 @@ jobs: DOCKER_NAMESPACE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]') echo "docker_namespace=${DOCKER_NAMESPACE}" >> ${GITHUB_OUTPUT} DOCKER_REPO=${DOCKER_REGISTRY}${DOCKER_NAMESPACE}/${{ steps.tag.outputs.repo_name }}-medley - if [ "${{ github.ref_name }}" = "main" ]; then devOrProd=production; else devOrProd=development; fi - DOCKER_TAGS="${DOCKER_REPO}:${devOrProd},${DOCKER_REPO}:${RELEASE_TAG#*-}_${MEDLEY_RELEASE#*-}_${MAIKO_RELEASE#*-}" + if [ "${{ inputs.draft }}" = true ] + then + devOrProd=development + else + devOrProd=production + fi + DOCKER_TAGS="${DOCKER_REPO}:${devOrProd},${DOCKER_REPO}:${MEDLEY_RELEASE#*-}_${MAIKO_RELEASE#*-}" echo "build_time=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> ${GITHUB_OUTPUT} echo "docker_tags=${DOCKER_TAGS}" >> ${GITHUB_OUTPUT} # Setup the Docker Machine Emulation environment. - name: Set up QEMU if: ${{ inputs.platform == 'linux/arm64' }} - uses: docker/setup-qemu-action@master + uses: docker/setup-qemu-action@v4 with: platforms: linux/arm64 # Setup the Docker Buildx funtion - name: Set up Docker Buildx id: buildx - uses: docker/setup-buildx-action@master + uses: docker/setup-buildx-action@v4 # Login to ghcr.io - name: Login to GitHub Container Registry - uses: docker/login-action@v3 + uses: docker/login-action@v4 with: registry: ghcr.io username: ${{ github.repository_owner }} @@ -176,7 +206,7 @@ jobs: # checked out and the release tars just downloaded. # Push the result to Docker Hub - name: Build Docker Image for Push to Docker Hub - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v7 with: builder: ${{ steps.buildx.outputs.name }} build-args: | diff --git a/.github/workflows/deployMedleyDocker.yml b/.github/workflows/deployMedleyDocker.yml index c6a8bec2..84bbe4ff 100644 --- a/.github/workflows/deployMedleyDocker.yml +++ b/.github/workflows/deployMedleyDocker.yml @@ -12,12 +12,21 @@ name: 'Deploy Online-Medley Docker Image' on: workflow_dispatch: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false workflow_call: secrets: OIO_SSH_KEY: required: true inputs: + draft: + description: "Deploy to Development instead of Production" + type: boolean + default: false + required: false platform: description: "linux/amd64 or linux/arm64" type: string @@ -34,7 +43,13 @@ jobs: run: | eval $(ssh-agent) ssh-add - <<< "${SSH_KEY}" - ssh -o StrictHostKeyChecking=no ubuntu@online.interlisp.org /home/ubuntu/bin/oio medley pullprod + if [ "${{ inputs.draft }}" = true ] + then + pull=pulldev + else + pull=pullprod + fi + ssh -o StrictHostKeyChecking=no ubuntu@online.interlisp.org /home/ubuntu/bin/oio medley ${pull} env: SSH_KEY: ${{ secrets.OIO_SSH_KEY }} From 30b81739c95651210402a344d465bbea15fb7b39 Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 04:36:04 +0000 Subject: [PATCH 02/10] Update descriptions on workflow options --- .github/workflows/buildAndDeployMedleyDocker.yml | 2 +- .github/workflows/buildMedleyDocker.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/buildAndDeployMedleyDocker.yml b/.github/workflows/buildAndDeployMedleyDocker.yml index df4b45a1..8f7a965a 100644 --- a/.github/workflows/buildAndDeployMedleyDocker.yml +++ b/.github/workflows/buildAndDeployMedleyDocker.yml @@ -19,7 +19,7 @@ on: type: boolean default: false github_release_tag: - description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + description: "Github Release tag from the Medley repo to use" type: string default: 'Latest' platform: diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index 3c64f19f..631734bc 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -24,7 +24,7 @@ on: type: boolean default: false github_release_tag: - description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + description: "Github Release tag from the Medley repo to use" type: string default: 'Latest' platform: @@ -44,7 +44,7 @@ on: default: false required: false github_release_tag: - description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + description: "Github Release tag from the Medley repo to use" type: string default: 'Latest' required: false From 0cd8baa4e6e6069f9e43347e7e6894798434d608 Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 04:42:27 +0000 Subject: [PATCH 03/10] More fixes to labels for workflow options --- .github/workflows/buildAndDeployMedleyDocker.yml | 6 +++--- .github/workflows/buildMedleyDocker.yml | 8 ++++---- .github/workflows/deployMedleyDocker.yml | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/buildAndDeployMedleyDocker.yml b/.github/workflows/buildAndDeployMedleyDocker.yml index 8f7a965a..b0071fc0 100644 --- a/.github/workflows/buildAndDeployMedleyDocker.yml +++ b/.github/workflows/buildAndDeployMedleyDocker.yml @@ -15,11 +15,11 @@ on: workflow_dispatch: inputs: draft: - description: "Deploy to Development instead of Production" + description: "Deploy to Development" type: boolean default: false github_release_tag: - description: "Github Release tag from the Medley repo to use" + description: "Github release tag from the Medley repo" type: string default: 'Latest' platform: @@ -41,7 +41,7 @@ on: default: false required: false github_release_tag: - description: "The tag of the Github Release from the Medley repo to use to build Online Medlet image" + description: "Github release tag from the Medley repo" type: string default: 'Latest' required: false diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index 631734bc..79008176 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -20,11 +20,11 @@ on: workflow_dispatch: inputs: draft: - description: "Deploy to Development instead of Production" + description: "Deploy to Development" type: boolean default: false github_release_tag: - description: "Github Release tag from the Medley repo to use" + description: "Github Release tag from the Medley repo" type: string default: 'Latest' platform: @@ -39,12 +39,12 @@ on: required: true inputs: draft: - description: "Deploy to Development instead of Production" + description: "Deploy to Development" type: boolean default: false required: false github_release_tag: - description: "Github Release tag from the Medley repo to use" + description: "Github Release tag from the Medley repo" type: string default: 'Latest' required: false diff --git a/.github/workflows/deployMedleyDocker.yml b/.github/workflows/deployMedleyDocker.yml index 84bbe4ff..bd44dd73 100644 --- a/.github/workflows/deployMedleyDocker.yml +++ b/.github/workflows/deployMedleyDocker.yml @@ -13,7 +13,7 @@ name: 'Deploy Online-Medley Docker Image' on: workflow_dispatch: draft: - description: "Deploy to Development instead of Production" + description: "Deploy to Development" type: boolean default: false @@ -23,7 +23,7 @@ on: required: true inputs: draft: - description: "Deploy to Development instead of Production" + description: "Deploy to Development" type: boolean default: false required: false From 4e128333215dd07e3f5fe17375e876a2fbd84275 Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 04:45:56 +0000 Subject: [PATCH 04/10] Typo in deploy.yml --- .github/workflows/deployMedleyDocker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/deployMedleyDocker.yml b/.github/workflows/deployMedleyDocker.yml index bd44dd73..102047ec 100644 --- a/.github/workflows/deployMedleyDocker.yml +++ b/.github/workflows/deployMedleyDocker.yml @@ -12,6 +12,7 @@ name: 'Deploy Online-Medley Docker Image' on: workflow_dispatch: + inputs: draft: description: "Deploy to Development" type: boolean From 28c637c0ef2ebd16bc5f426f13f34ea1ae65f5ff Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 04:51:27 +0000 Subject: [PATCH 05/10] Fix description of draft input in buildMedleyDocker.yml --- .github/workflows/buildMedleyDocker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index 79008176..c2377980 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -20,7 +20,7 @@ on: workflow_dispatch: inputs: draft: - description: "Deploy to Development" + description: "Mark as Development" type: boolean default: false github_release_tag: From 0293d2d90f8f7465282a587feb3a7413b3246b3e Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 05:11:52 +0000 Subject: [PATCH 06/10] debugging buildMedleyDocker.yml --- .github/workflows/buildMedleyDocker.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index c2377980..a4e54dda 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -121,6 +121,7 @@ jobs: - name: Get info from latest Medley image id: release_info run: | + set -x if [ "${{ inputs.github_release_tag }}" = "Latest" ] || [ "${{ inputs.github_release_tag }}" = "latest" ] then DOCKER_TAG=latest @@ -131,7 +132,9 @@ jobs: DOCKER_NAMESPACE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]') echo "docker_namespace=${DOCKER_NAMESPACE}" >> $GITHUB_OUTPUT docker pull "${DOCKER_NAMESPACE}/medley:${DOCKER_TAG}" - RELEASE_INFO=$(docker run --entrypoint /bin/bash ${DOCKER_NAMESPACE}/medley:latest -c "echo \${MAIKO_RELEASE}::::\${MEDLEY_RELEASE}") + RELEASE_INFO= \ + $(docker run --entrypoint /bin/bash ${DOCKER_NAMESPACE}/medley:${DOCKER_TAG} \ + -c "echo \${MAIKO_RELEASE}::::\${MEDLEY_RELEASE}") MAIKO_RELEASE=${RELEASE_INFO%::::*} MEDLEY_RELEASE=${RELEASE_INFO#*::::} echo "MAIKO_RELEASE=${MAIKO_RELEASE}" >> ${GITHUB_ENV} From 1ade942f0b93d046b8a0219eb2b1abe64db1a0cd Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 05:14:55 +0000 Subject: [PATCH 07/10] Fix typo in buildMedleyDocker.yml --- .github/workflows/buildMedleyDocker.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index a4e54dda..8d0b9fb0 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -121,14 +121,13 @@ jobs: - name: Get info from latest Medley image id: release_info run: | - set -x if [ "${{ inputs.github_release_tag }}" = "Latest" ] || [ "${{ inputs.github_release_tag }}" = "latest" ] then DOCKER_TAG=latest else DOCKER_TAG="${{ inputs.github_release_tag }}" DOCKER_TAG="${DOCKER_TAG##medley-}" - endif + fi DOCKER_NAMESPACE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]') echo "docker_namespace=${DOCKER_NAMESPACE}" >> $GITHUB_OUTPUT docker pull "${DOCKER_NAMESPACE}/medley:${DOCKER_TAG}" From 77736fa44507673e498d867d1e14f2d5d974c2cd Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Fri, 20 Mar 2026 05:21:08 +0000 Subject: [PATCH 08/10] Debugging buildMedleyDocker.yml --- .github/workflows/buildMedleyDocker.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/buildMedleyDocker.yml b/.github/workflows/buildMedleyDocker.yml index 8d0b9fb0..3014b572 100644 --- a/.github/workflows/buildMedleyDocker.yml +++ b/.github/workflows/buildMedleyDocker.yml @@ -131,9 +131,7 @@ jobs: DOCKER_NAMESPACE=$(echo "${{ github.repository_owner }}" | tr '[:upper:]' '[:lower:]') echo "docker_namespace=${DOCKER_NAMESPACE}" >> $GITHUB_OUTPUT docker pull "${DOCKER_NAMESPACE}/medley:${DOCKER_TAG}" - RELEASE_INFO= \ - $(docker run --entrypoint /bin/bash ${DOCKER_NAMESPACE}/medley:${DOCKER_TAG} \ - -c "echo \${MAIKO_RELEASE}::::\${MEDLEY_RELEASE}") + RELEASE_INFO=$(docker run --entrypoint /bin/bash ${DOCKER_NAMESPACE}/medley:${DOCKER_TAG} -c "echo \${MAIKO_RELEASE}::::\${MEDLEY_RELEASE}") MAIKO_RELEASE=${RELEASE_INFO%::::*} MEDLEY_RELEASE=${RELEASE_INFO#*::::} echo "MAIKO_RELEASE=${MAIKO_RELEASE}" >> ${GITHUB_ENV} From ec1bd883b2dac6de21a7543042c20558918bd07d Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Sat, 21 Mar 2026 06:25:52 +0000 Subject: [PATCH 09/10] Fix references to github_release_tag in buildAndDeployMedleyDocker.yml --- .github/workflows/buildAndDeployMedleyDocker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/buildAndDeployMedleyDocker.yml b/.github/workflows/buildAndDeployMedleyDocker.yml index b0071fc0..9f600c48 100644 --- a/.github/workflows/buildAndDeployMedleyDocker.yml +++ b/.github/workflows/buildAndDeployMedleyDocker.yml @@ -60,7 +60,7 @@ jobs: uses: ./.github/workflows/buildMedleyDocker.yml with: draft: ${{ inputs.draft }} - github.release.tag: ${{ inputs.github.release.tag }} + github_release_tag: ${{ inputs.github_release_tag }} platform: ${{ inputs.platform }} secrets: CCRYPT_KEY: ${{ secrets.CCRYPT_KEY }} @@ -69,7 +69,7 @@ jobs: uses: ./.github/workflows/deployMedleyDocker.yml with: draft: ${{ inputs.draft }} - github.release.tag: ${{ inputs.github.release.tag }} + github_release_tag: ${{ inputs.github_release_tag }} secrets: OIO_SSH_KEY: ${{ secrets.OIO_SSH_KEY }} From 984e2b7a20cf879bcf03057ed876d8a6a72a0cc1 Mon Sep 17 00:00:00 2001 From: Frank Halasz Date: Mon, 23 Mar 2026 05:44:18 +0000 Subject: [PATCH 10/10] Fix error in calling depolyMedleyDocker from buildAndDeployMedleyDocker --- .github/workflows/buildAndDeployMedleyDocker.yml | 1 - .github/workflows/deployMedleyDocker.yml | 4 ++++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/buildAndDeployMedleyDocker.yml b/.github/workflows/buildAndDeployMedleyDocker.yml index 9f600c48..3b598e3e 100644 --- a/.github/workflows/buildAndDeployMedleyDocker.yml +++ b/.github/workflows/buildAndDeployMedleyDocker.yml @@ -69,7 +69,6 @@ jobs: uses: ./.github/workflows/deployMedleyDocker.yml with: draft: ${{ inputs.draft }} - github_release_tag: ${{ inputs.github_release_tag }} secrets: OIO_SSH_KEY: ${{ secrets.OIO_SSH_KEY }} diff --git a/.github/workflows/deployMedleyDocker.yml b/.github/workflows/deployMedleyDocker.yml index 102047ec..01a94ca9 100644 --- a/.github/workflows/deployMedleyDocker.yml +++ b/.github/workflows/deployMedleyDocker.yml @@ -17,6 +17,10 @@ on: description: "Deploy to Development" type: boolean default: false + platform: + description: "linux/amd64 or linux/arm64" + type: string + default: 'linux/amd64' workflow_call: secrets: