Skip to content

Commit

Permalink
Release Faster (#486)
Browse files Browse the repository at this point in the history
* Do not run tests again on release since they've been run at least 2 times before.

* remove needs

* fix conditions
  • Loading branch information
bwagner5 authored Aug 24, 2021
1 parent f6d251b commit aba9b8d
Showing 1 changed file with 21 additions and 17 deletions.
38 changes: 21 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ jobs:
fastTests:
name: Fast Tests and Lints
runs-on: ubuntu-20.04
if: ${{ !contains(github.ref, 'refs/tags/') }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand Down Expand Up @@ -43,6 +44,7 @@ jobs:
buildLinux:
name: Build Linux Binaries
runs-on: ubuntu-20.04
if: ${{ !contains(github.ref, 'refs/tags/') }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand All @@ -57,6 +59,7 @@ jobs:
buildLinuxDocker:
name: Build Linux Docker Images
runs-on: ubuntu-20.04
if: ${{ !contains(github.ref, 'refs/tags/') }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand All @@ -72,6 +75,7 @@ jobs:
buildWindows:
name: Build Windows Binaries
runs-on: windows-2019
if: ${{ !contains(github.ref, 'refs/tags/') }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand All @@ -87,6 +91,7 @@ jobs:
buildWindowsDocker:
name: Build Windows Docker Images
runs-on: windows-2019
if: ${{ !contains(github.ref, 'refs/tags/') }}
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
Expand All @@ -99,28 +104,28 @@ jobs:
- name: Build Windows Docker Images
run: choco install make && RefreshEnv.cmd && make build-docker-images-windows

# e2e:
# name: E2E Tests
# runs-on: ubuntu-20.04
# strategy:
# matrix:
# k8sVersion: ["1.16", "1.17", "1.18", "1.19", "1.20", "1.21"]
# steps:
# - name: Set up Go 1.x
# uses: actions/setup-go@v2
# with:
# go-version: ${{ env.DEFAULT_GO_VERSION }}
e2e:
name: E2E Tests
runs-on: ubuntu-20.04
if: ${{ !contains(github.ref, 'refs/tags/') }}
strategy:
matrix:
k8sVersion: ["1.16", "1.17", "1.18", "1.19", "1.20", "1.21"]
steps:
- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ${{ env.DEFAULT_GO_VERSION }}

# - name: Check out code into the Go module directory
# uses: actions/checkout@v2
- name: Check out code into the Go module directory
uses: actions/checkout@v2

# - name: E2E Tests
# run: test/k8s-local-cluster-test/run-test -v ${{ matrix.k8sVersion }}
- name: E2E Tests
run: test/k8s-local-cluster-test/run-test -v ${{ matrix.k8sVersion }}

releaseLinux:
name: Release Linux
runs-on: ubuntu-20.04
needs: [buildWindows, buildWindowsDocker, buildLinux, buildLinuxDocker, fastTests]
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
steps:
- name: Set up Go 1.x
Expand All @@ -141,7 +146,6 @@ jobs:
releaseWindows:
name: Release Windows
runs-on: windows-2019
needs: [buildWindows, buildWindowsDocker, buildLinux, buildLinuxDocker, fastTests]
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
steps:
- name: Set up Go 1.x
Expand Down

0 comments on commit aba9b8d

Please sign in to comment.