fix(agents): Prevent Docker output pollution and skip agent pulling in container mode #1482
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: CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths-ignore: | |
| - '**/*.md' | |
| pull_request: | |
| branches: | |
| - main | |
| paths-ignore: | |
| - '**/*.md' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| prepare: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Setup Go | |
| uses: actions/setup-go@v6.2.0 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Prepare project | |
| run: | | |
| go mod tidy | |
| go fmt ./... | |
| - name: Check for dirty project | |
| run: | | |
| if [ -n "$(git status --porcelain)" ]; then | |
| echo "Project has uncommitted changes:" | |
| git status --porcelain | |
| git diff | |
| exit 1 | |
| fi | |
| echo "Project is clean" | |
| lint: | |
| needs: | |
| - prepare | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Setup Go | |
| uses: actions/setup-go@v6.2.0 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Install golangci-lint | |
| uses: golangci/golangci-lint-action@v9.2.0 | |
| with: | |
| version: v2.8.0 | |
| args: --timeout=5m | |
| vet: | |
| needs: | |
| - prepare | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Setup Go | |
| uses: actions/setup-go@v6.2.0 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Run vet | |
| run: go vet ./... | |
| build: | |
| needs: | |
| - lint | |
| - vet | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Setup Go | |
| uses: actions/setup-go@v6.2.0 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Build project | |
| run: | | |
| go build \ | |
| -ldflags "\ | |
| -w -s \ | |
| -X github.com/inference-gateway/cli/cmd.version=${{ github.ref_name }} \ | |
| -X github.com/inference-gateway/cli/cmd.commit=${{ github.sha }} \ | |
| -X github.com/inference-gateway/cli/cmd.date=$(date -u +"%Y-%m-%dT%H:%M:%SZ")" \ | |
| -o infer . | |
| test: | |
| needs: | |
| - build | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Setup Go | |
| uses: actions/setup-go@v6.2.0 | |
| with: | |
| go-version-file: 'go.mod' | |
| cache: true | |
| - name: Run tests | |
| run: go test ./... |