just return the 0 to make this hotpath faster #96
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: lint-test | |
on: | |
push: | |
jobs: | |
run: | |
permissions: | |
contents: read | |
runs-on: ubuntu-24.04 | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5 | |
with: | |
go-version: '>=1.24.0' | |
- name: golangci-lint | |
uses: golangci/golangci-lint-action@2226d7cb06a077cd73e56eedd38eecad18e5d837 # v6 | |
with: | |
version: latest | |
- name: check YML | |
run: yq . .traefik.yml | |
- name: go mod tidy | |
run: | | |
go mod tidy | |
if ! git diff --exit-code go.mod go.sum; then | |
echo "Error: go.mod or go.sum is not tidy. Run 'go mod tidy' locally and commit the changes." | |
exit 1 | |
fi | |
- name: go mod vendor | |
run: | | |
go mod vendor | |
if ! git diff --exit-code vendor/; then | |
echo "Error: vendor/ directory is not up-to-date. Run 'go mod vendor' locally and commit the changes." | |
exit 1 | |
fi | |
- name: unit test | |
run: go test -v -race ./... | |
integration-test: | |
needs: [run] | |
permissions: | |
contents: read | |
runs-on: ubuntu-24.04 | |
strategy: | |
matrix: | |
traefik: [v2.11, v3.0, v3.1, v3.2, v3.3] | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | |
- name: run | |
run: go run test.go | |
working-directory: ./ci | |
env: | |
TRAEFIK_TAG: ${{ matrix.traefik }} | |
- name: cleanup | |
if: ${{ always() }} | |
run: docker compose down | |
working-directory: ./ci |