From 4f7f2627b78ac8f722d1d1c1dace6b281d6de52d Mon Sep 17 00:00:00 2001 From: Maxime Jublou Date: Wed, 31 Jul 2024 12:04:56 +0200 Subject: [PATCH] ci: Working on schedulers --- .github/scripts/generate_schedulers.py | 6 +++--- .github/workflows/scheduler__main.yaml | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/scripts/generate_schedulers.py b/.github/scripts/generate_schedulers.py index 65ad802..41aac0b 100644 --- a/.github/scripts/generate_schedulers.py +++ b/.github/scripts/generate_schedulers.py @@ -22,11 +22,11 @@ password: ${{ secrets.GITHUB_TOKEN }} - name: Pull Docker image - run: docker pull ghcr.io/jupyter-naas/abi/abi:latest + run: docker pull ghcr.io/${{ github.repository }}/abi:latest # - name: Run Papermill # run: | - # docker run --name abi-execution -i --platform linux/amd64 ghcr.io/jupyter-naas/abi/abi:latest ls + # docker run --name abi-execution -i --platform linux/amd64 ghcr.io/${{ github.repository }}/abi:latest ls # mkdir output # docker cp abi-execution:/app/__pipeline__.ipynb ./output/__pipeline__.ipynb @@ -62,7 +62,7 @@ def generate_schedulers(config : dict, template : str): export SCHEDULER_ID=$(python -c "import uuid; print(uuid.uuid4())") # Execute the Scheduler script -docker run --name $SCHEDULER_ID -i --platform linux/amd64 ghcr.io/jupyter-naas/abi/abi:latest python .github/scripts/run_scheduler.py "{scheduler['name']}" +docker run --name $SCHEDULER_ID -i --platform linux/amd64 ghcr.io/${{ github.repository }}/abi:latest python .github/scripts/run_scheduler.py "{scheduler['name']}" # Create the output directory that will be used to store the output files and save them as artifacts. mkdir -p outputs/ diff --git a/.github/workflows/scheduler__main.yaml b/.github/workflows/scheduler__main.yaml index aa68962..efed627 100644 --- a/.github/workflows/scheduler__main.yaml +++ b/.github/workflows/scheduler__main.yaml @@ -11,7 +11,7 @@ jobs: registry: ghcr.io username: ${{ github.actor }} - name: Pull Docker image - run: docker pull ghcr.io/jupyter-naas/abi/abi:latest + run: docker pull ghcr.io/${{ github.repository }}/abi:latest - name: main run: ' @@ -22,8 +22,8 @@ jobs: # Execute the Scheduler script - docker run --name $SCHEDULER_ID -i --platform linux/amd64 ghcr.io/jupyter-naas/abi/abi:latest - python .github/scripts/run_scheduler.py "main" + docker run --name $SCHEDULER_ID -i --platform linux/amd64 ghcr.io/${ github.repository + }/abi:latest python .github/scripts/run_scheduler.py "main" # Create the output directory that will be used to store the output files