diff options
author | 2020-11-18 11:14:07 +0100 | |
---|---|---|
committer | 2020-11-18 11:14:07 +0100 | |
commit | 741ae614be339b940a183a6678b9424f3dde39cf (patch) | |
tree | 6749090cf288d6b446640412e0c3f65d7c6e7478 | |
parent | Use environment var for production build bool (diff) |
Clean up workflow file
-rw-r--r-- | .github/workflows/lint-test.yaml | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/.github/workflows/lint-test.yaml b/.github/workflows/lint-test.yaml index eb879c0..506467e 100644 --- a/.github/workflows/lint-test.yaml +++ b/.github/workflows/lint-test.yaml @@ -10,7 +10,12 @@ jobs: lint-test: runs-on: ubuntu-latest env: - production_build: ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/sebastiaan/backend/cache-docker-images' }} + # Determine whether or not we should build the + # final production image and push it to GHCR. + production_build: ${{ + github.event_name != 'pull_request' && + github.ref == 'refs/heads/master' + }} steps: # Create a short SHA-tag to tag built images @@ -100,7 +105,8 @@ jobs: # wrong where. - name: Run linter run: "docker exec snekbox_test /bin/bash -c 'flake8 \ - --format \"::error file=%(path)s,line=%(row)d,col=%(col)d::[flake8] %(code)s: %(text)s\"'" + --format \"::error file=%(path)s,line=%(row)d,col=%(col)d::\ + [flake8] %(code)s: %(text)s\"'" # Memory limit tests would fail if this isn't disabled. - name: Disable swap memory @@ -146,12 +152,6 @@ jobs: # the run, so it does not make sense to drop down to a completely # fresh build environment in a new worker/runner. - - name: print output - run: | - echo "${{ github.ref }}" - echo "${{ env.production_build }}" - echo "${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/sebastiaan/backend/cache-docker-images' }}" - # Build the final production image and push it to GHCR, tagging it # both with the short commit SHA and 'latest'. This step should use # the cache that was just generated when we built the test container. |