mirror of
https://github.com/allenai/olmocr.git
synced 2025-11-03 11:35:29 +00:00
Beaker push fix
This commit is contained in:
parent
5e5c31b93e
commit
08ca1544bf
23
.github/workflows/main.yml
vendored
23
.github/workflows/main.yml
vendored
@ -281,15 +281,22 @@ jobs:
|
||||
env:
|
||||
BEAKER_TOKEN: ${{ secrets.BEAKER_TOKEN }}
|
||||
run: |
|
||||
# Get the version without 'v' prefix
|
||||
VERSION=${GITHUB_REF#refs/tags/v}
|
||||
|
||||
# Push the Docker image to Beaker
|
||||
beaker image create \
|
||||
# Get version
|
||||
VERSION=${{ steps.meta.outputs.version }}
|
||||
|
||||
# Get the image ID for the versioned tag
|
||||
IMAGE_ID=$(docker images --format "{{.Repository}}:{{.Tag}} {{.ID}}" | grep "alleninstituteforai/olmocr:$VERSION" | awk '{print $2}')
|
||||
|
||||
if [ -z "$IMAGE_ID" ]; then
|
||||
echo "ERROR: Could not find image ID for tag alleninstituteforai/olmocr:$VERSION"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Push the Docker image to Beaker using the image ID
|
||||
beaker image create "$IMAGE_ID" \
|
||||
--name "olmocr-inference-$VERSION" \
|
||||
--workspace ai2/olmocr \
|
||||
"docker://${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:$VERSION"
|
||||
|
||||
--workspace ai2/olmocr
|
||||
|
||||
- name: Clean up after build
|
||||
if: always()
|
||||
run: |
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user