disable simplego cicd tests #11
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 models | |
| on: | |
| push: | |
| branches: | |
| - '**' | |
| # on: workflow_dispatch | |
| permissions: | |
| contents: write | |
| packages: write | |
| checks: write | |
| attestations: write | |
| id-token: write | |
| env: | |
| REGISTRY: ghcr.io | |
| IMAGE_NAME: ${{ github.repository }} | |
| jobs: | |
| build: | |
| name: build test model | |
| runs-on: ubuntu-latest | |
| env: | |
| CI: true | |
| steps: | |
| - name: Set up Go | |
| uses: actions/setup-go@v2 | |
| with: | |
| go-version: '1.24.5' | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| go mod download | |
| - name: download models | |
| run: | | |
| go run testData/downloadModels.go | |
| - name: List models directory | |
| run: ls -l ./models | |
| - name: Remove models from .dockerignore # make sure models folder is not ignored | |
| run: sed -i '/^\/models$/d' .dockerignore | |
| - name: Log in to the Container registry | |
| uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1 | |
| with: | |
| registry: ${{ env.REGISTRY }} | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build and push Docker image | |
| uses: docker/build-push-action@v5 | |
| with: | |
| context: . | |
| file: models.Dockerfile | |
| tags: ghcr.io/knights-analytics/hugot/models:latest | |
| push: true |