Skip to content

fix(llm): default analysis to failed pipelines only #938

fix(llm): default analysis to failed pipelines only

fix(llm): default analysis to failed pipelines only #938

Workflow file for this run

name: Create and publish a Docker image to ghcr on main and nightly with ko
on:
push:
paths:
- "cmd/**"
- "pkg/**"
- "vendor/**"
- "go.mod"
- "go.sum"
- ".ko.yaml"
- ".github/workflows/container.yaml"
# For testing when pushing to the main repo directly on pr
# pull_request:
# paths:
# - "cmd/**"
# - "pkg/**"
# - "vendor/**"
# - "go.mod"
# - "go.sum"
# - ".ko.yaml"
# - ".github/workflows/container.yaml"
env:
PLATFORMS: linux/amd64,linux/arm64,linux/ppc64le
jobs:
build-and-push-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
- name: Set up Go
uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6
with:
go-version-file: "go.mod"
- uses: ko-build/setup-ko@d006021bd0c28d1ce33a07e7943d48b079944c8d # v0.9
- name: Build and push images
shell: bash
run: |
set -x
releaseBranchFormat='release-v'
if [[ ${{ github.ref_name }} == ${releaseBranchFormat}* ]]; then
tag=v$(echo ${{ github.ref_name }}|sed "s,${releaseBranchFormat},,")
elif [[ ${{ github.ref }} == refs/pull/* ]]; then
tag=pr-$(echo ${{ github.ref }} | cut -c11-|sed 's,/merge,,')
else
# Sanitize the tag by replacing invalid characters with hyphens
tag=$(echo ${{ github.ref_name }}|sed 's,/merge,,' | sed 's,[/.],-,g')
fi
for image in ./cmd/*;do
ko build -B -t "${tag}" --platform="${{ env.PLATFORMS }}" "${image}"
done