Improves README's #86
Workflow file for this run
This file contains 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: ci | |
on: | |
pull_request: | |
branches: | |
- '**' | |
jobs: | |
backend-lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22.7' | |
cache: false | |
- name: Run linter | |
working-directory: ./backend | |
run: | | |
test -z $(gofmt -l .) | |
backend-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22.7' | |
cache: false | |
- name: Run tests | |
working-directory: ./backend | |
run: | | |
go test -race github.com/kubetail-org/kubetail/backend/... | |
backend-vet: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version: '1.22.7' | |
cache: false | |
- name: Run code vetter | |
working-directory: ./backend | |
run: | | |
go vet github.com/kubetail-org/kubetail/backend/... | |
frontend-lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- uses: pnpm/action-setup@v3 | |
with: | |
version: 9 | |
- name: Set up and run linter | |
working-directory: ./frontend | |
run: | | |
pnpm install | |
pnpm lint | |
frontend-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- uses: pnpm/action-setup@v3 | |
with: | |
version: 9 | |
- name: Set up and run tests | |
working-directory: ./frontend | |
run: | | |
pnpm install | |
pnpm test run | |
frontend-build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- uses: pnpm/action-setup@v3 | |
with: | |
version: 9 | |
- name: Set up and run build script | |
working-directory: ./frontend | |
run: | | |
pnpm install | |
pnpm build | |
build-amd64-server: | |
needs: | |
- backend-lint | |
- backend-test | |
- backend-vet | |
- frontend-lint | |
- frontend-test | |
- frontend-build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
file: build/package/Dockerfile.server | |
push: false | |
tags: kubetail-server:latest | |
build-amd64-agent: | |
needs: | |
- backend-lint | |
- backend-test | |
- backend-vet | |
- frontend-lint | |
- frontend-test | |
- frontend-build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
file: build/package/Dockerfile.agent | |
push: false | |
tags: kubetail-agent:latest | |
build-arm64-sever: | |
needs: | |
- backend-lint | |
- backend-test | |
- backend-vet | |
- frontend-lint | |
- frontend-test | |
- frontend-build | |
runs-on: arm64-ubuntu-22 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
file: build/package/Dockerfile.server | |
push: false | |
tags: kubetail-server:latest | |
build-arm64-agent: | |
needs: | |
- backend-lint | |
- backend-test | |
- backend-vet | |
- frontend-lint | |
- frontend-test | |
- frontend-build | |
runs-on: arm64-ubuntu-22 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
file: build/package/Dockerfile.agent | |
push: false | |
tags: kubetail-agent:latest |