Build & test project #3051
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build & test project | |
on: | |
push: | |
schedule: | |
- cron: "0 6 * * *" | |
jobs: | |
build: | |
name: Build & check format | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Protoc | |
uses: arduino/setup-protoc@v3 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Install clippy on stable | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: clippy | |
- run: cargo build | |
- run: cargo clippy --all-targets --all-features -- -D warnings | |
- name: Set nightly for cargo fmt | |
uses: dtolnay/rust-toolchain@nightly | |
with: | |
components: rustfmt | |
- run: cargo +nightly fmt -- --check | |
integration-test: | |
name: Integration test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: 1.22 | |
- name: Install latest version of Kind | |
run: go install sigs.k8s.io/[email protected] | |
- run: PATH=$(go env GOPATH)/bin:$PATH kind version | |
- name: Create Kind cluster | |
run: PATH=$(go env GOPATH)/bin:$PATH kind create cluster --config kind-config.yaml | |
- name: Install skaffold | |
run: | | |
curl -Lo skaffold https://storage.googleapis.com/skaffold/releases/latest/skaffold-linux-amd64 | |
chmod +x skaffold | |
sudo mv skaffold /usr/local/bin | |
- run: skaffold version | |
- run: make bootstrap | |
- run: make e2e |