3939 -
uses :
webfactory/[email protected] 4040 with :
4141 ssh-private-key : ${{ secrets.SSH_PRIVATE_KEY }}
42+ - name : prepare image tag
43+ id : prepare-tag
44+ if : ${{ inputs.build_vector_db_image == 'true' }}
45+ shell : bash
46+ run : |
47+ branch_tmp=$(git rev-parse --abbrev-ref HEAD)
48+ branch=${branch_tmp//\//-} # replace all / with -
49+ tag="ghcr.io/${{ github.repository_owner }}/vector-db-benchmark:${branch}"
50+ echo "Use tag ${tag}"
51+ echo "tag=${tag}" >> $GITHUB_OUTPUT
4252 - name : Set up Docker Buildx
4353 if : ${{ inputs.build_vector_db_image == 'true' }}
4454 uses : docker/setup-buildx-action@v3
@@ -47,16 +57,18 @@ jobs:
4757 uses : docker/login-action@v3
4858 with :
4959 registry : ghcr.io
50- username : qdrant
60+ username : ${{ github.repository_owner }}
5161 password : ${{ secrets.GITHUB_TOKEN }}
5262 - name : Build Vector DB image
5363 if : ${{ inputs.build_vector_db_image == 'true' }}
5464 uses : docker/build-push-action@v6
5565 with :
5666 context : .
5767 push : true
58- tags : ghcr.io/qdrant/vector-db-benchmark: ${{ github.ref_name }}
68+ tags : ${{ steps.prepare-tag.outputs.tag }}
5969 provenance : false
70+ cache-from : type=gha
71+ cache-to : type=gha,mode=max
6072 - name : Benches
6173 run : |
6274 export HCLOUD_TOKEN=${{ secrets.HCLOUD_TOKEN }}
6880 export POSTGRES_TABLE=benchmark_manual
6981 export QDRANT__FEATURE_FLAGS__ALL=${{ inputs.feature_flags_all }}
7082 if [ "${{ inputs.build_vector_db_image }}" = "true" ]; then
71- export VECTOR_DB_BENCHMARK_IMAGE=ghcr.io/qdrant/vector-db-benchmark:${{ github.ref_name }}
83+ export VECTOR_DB_BENCHMARK_IMAGE=${{ steps.prepare-tag.outputs.tag }}
84+ export GHCR_USERNAME=${{ github.repository_owner }}
7285 export GHCR_PASSWORD=${{ secrets.GITHUB_TOKEN }}
7386 fi
7487 bash -x tools/setup_ci.sh
0 commit comments