Skip to content

add cd

add cd #4

Workflow file for this run

name: CI
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
tags:
- "v*"
env:
CARGO_TERM_COLOR: always
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse
concurrency:
group: ${{ github.workflow }}-${{ github.ref || github.run_id }}
cancel-in-progress: true
jobs:
test:
strategy:
fail-fast: false
matrix:
platform:
- ubuntu-24.04
- ubuntu-24.04-arm
name: ${{ matrix.platform }} / test
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v6
- name: Configure toolchain
run: |
rustup toolchain install --profile minimal --no-self-update stable
rustup default stable
- uses: Swatinem/rust-cache@v2
- run: cargo test
clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Configure toolchain
run: |
rustup toolchain install --profile minimal --no-self-update stable
rustup default stable
rustup component add clippy
- uses: Swatinem/rust-cache@v2
- run: cargo clippy --all-targets --all-features
kubeconform:
name: Lint Kubernetes manifests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install kubeconform
run: |
curl -fsSL https://github.com/yannh/kubeconform/releases/latest/download/kubeconform-linux-amd64.tar.gz \
| tar xz -C /usr/local/bin kubeconform
- run: kubeconform -strict -summary operator.yaml
tests-pass:
if: always()
name: Tests pass
needs: [test, clippy, kubeconform]
runs-on: ubuntu-latest
steps:
- uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}