diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index 56be2a7..8bad012 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -16,12 +16,12 @@ on: jobs: build: name: Kheops-compiled Docker ${{ github.event_name }} - runs-on: [self-hosted] + runs-on: [ubuntu-latest] steps: - name: Checkout current project repository uses: actions/checkout@v3 with: - path: testing_project_Angular + path: ${{ env.REPOSITORY_DIR }} - name: Comment PR uses: thollander/actions-comment-pull-request@v2 with: @@ -37,6 +37,8 @@ jobs: docker pull terrastruct/d2:v0.6.5 - id: run_docker_image name: Run Kheops-compiled + env: + IMGBB_KEY: ${{ secrets.IMGBB_KEY }} run: | mkdir -p ./output echo 'DATA_DUMP<> $GITHUB_OUTPUT @@ -64,7 +66,7 @@ jobs: docker run --rm -u "$(id -u):$(id -g)" -v "$PWD:/home/debian/src" terrastruct/d2:v0.6.5 ./output/diagram.d2 ./output/diagram.png echo '```' >> $GITHUB_OUTPUT - echo "![Diagram]($(curl -X POST "https://api.imgbb.com/1/upload" -F "key=a1c8eaba9c93fdb65c7961d1d74b7ef4" -F "image=@./output/diagram.png" | jq -r '.data.image.url'))" >> $GITHUB_OUTPUT + echo "![Diagram]($(curl -X POST "https://api.imgbb.com/1/upload" -F "key=$IMGBB_KEY" -F "image=@./output/diagram.png" | jq -r '.data.image.url'))" >> $GITHUB_OUTPUT echo 'EOF' >> $GITHUB_OUTPUT - name: Edit PR comment diff --git a/.github/workflows/ci-push.yml b/.github/workflows/ci-push.yml index c4942f4..3e4ec72 100644 --- a/.github/workflows/ci-push.yml +++ b/.github/workflows/ci-push.yml @@ -16,12 +16,12 @@ on: jobs: build: name: Kheops-compiled Docker ${{ github.event_name }} - runs-on: [self-hosted] + runs-on: [ubuntu-latest] steps: - name: Checkout current project repository uses: actions/checkout@v3 with: - path: testing_project_Angular + path: ${{ env.REPOSITORY_DIR }} - id: pull_docker_image name: Pull Kheops-compiled container image run: |