feat: Add taylor diagrams #118
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 Container | |
| on: | |
| pull_request: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - "main" | |
| tags: | |
| - "v*" | |
| permissions: | |
| contents: read | |
| packages: write | |
| attestations: write | |
| id-token: write | |
| jobs: | |
| climate-ref-frontend: | |
| name: climate-ref-frontend | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: docker/setup-buildx-action@v3 | |
| - uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - uses: docker/metadata-action@v5 | |
| id: metadata | |
| with: | |
| images: ghcr.io/${{ github.repository_owner }}/climate-ref-frontend | |
| tags: | | |
| type=ref,event=pr | |
| type=ref,event=tag | |
| # set latest tag for default branch | |
| type=raw,value=main,enable={{is_default_branch}} | |
| - uses: docker/build-push-action@v4 | |
| id: push | |
| with: | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max | |
| context: . | |
| file: Dockerfile | |
| push: ${{ ! github.event.pull_request.head.repo.fork }} | |
| sbom: true | |
| tags: ${{ steps.metadata.outputs.tags }} | |
| labels: ${{ steps.metadata.outputs.labels }} | |
| - name: Attest to climate-ref-frontend image | |
| uses: actions/attest-build-provenance@v2 | |
| if: ${{ ! github.event.pull_request.head.repo.fork }} | |
| with: | |
| subject-name: ghcr.io/${{ github.repository_owner }}/climate-ref-frontend | |
| subject-digest: ${{ steps.push.outputs.digest }} | |
| push-to-registry: true |