From 0357840bbd4208a9f836ed67c11dfa5ff19a1b22 Mon Sep 17 00:00:00 2001 From: Casper da Costa-Luis Date: Wed, 5 May 2021 19:28:56 +0100 Subject: [PATCH] more tidy and fix bot tests - follow up to #494 --- .github/workflows/checkbot.yml | 17 +++++++++++------ .github/workflows/release.yml | 9 +-------- 2 files changed, 12 insertions(+), 14 deletions(-) diff --git a/.github/workflows/checkbot.yml b/.github/workflows/checkbot.yml index a6f518315..6106bf617 100644 --- a/.github/workflows/checkbot.yml +++ b/.github/workflows/checkbot.yml @@ -12,18 +12,23 @@ jobs: - name: Build & Publish test image run: | echo "${{ secrets.DOCKERHUB_PASSWORD }}" | docker login -u ${{ secrets.DOCKERHUB_USERNAME }} --password-stdin - - docker build -t dvcorg/cml -f ./docker/Dockerfile . - docker build -t dvcorg/cml-py3 -f ./docker/Dockerfile-py3 . - - docker tag dvcorg/cml dvcorg/cml-test - docker push dvcorg/cml-test + docker build \ + --build-arg "CML_VERSION=$CML_VERSION" \ + --build-arg "DVC_VERSION=$DVC_VERSION" \ + --build-arg "PYTHON_VERSION=$PYTHON_VERSION" \ + --build-arg "BASE_IMAGE=$BASE_IMAGE" \ + -t dvcorg/cml-test . docker run --name runner --rm \ -e "REPO_TOKEN=${{ secrets.TEST_GITHUB_TOKEN }}" \ -e "RUNNER_REPO=https://github.com/${GITHUB_REPOSITORY}" \ -e "RUNNER_LABELS=cml-docker" \ -e "RUNNER_IDLE_TIMEOUT=10" \ dvcorg/cml-test + env: + CML_VERSION: 0 + DVC_VERSION: 2 + PYTHON_VERSION: 3.8 + BASE_IMAGE: 'ubuntu:20.04' # test container all CML features, vega and actions with issues in the past check-container: needs: build-container diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 6f58adea3..5e13e33e5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,12 +1,8 @@ name: Release packages and images - on: workflow_dispatch: release: - types: - - published - - edited - + types: [published, edited] jobs: package: runs-on: ubuntu-latest @@ -16,7 +12,6 @@ jobs: - run: npm publish env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - docker: strategy: matrix: @@ -37,7 +32,6 @@ jobs: ubuntu: 20.04 runs-on: ubuntu-latest needs: package - steps: - uses: actions/checkout@v2 - uses: docker/setup-buildx-action@v1 @@ -59,7 +53,6 @@ jobs: DVC_VERSION=${{ matrix.dvc }} PYTHON_VERSION=${{ matrix.python }} BASE_IMAGE=ubuntu:${{ matrix.ubuntu }} - - uses: docker/build-push-action@v2 if: matrix.gpu == true with: