Skip to content

Commit

Permalink
try deploying to app-service right after build
Browse files Browse the repository at this point in the history
  • Loading branch information
Administrator committed Oct 3, 2024
1 parent 9585b82 commit dfaabbf
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions .github/workflows/build-deploy-ocr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:

env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
# IMAGE_NAME: ${{ github.repository }}
# VERSION: ${{ inputs.tag }}
VERSION: test-deploy-1

Expand All @@ -27,22 +27,16 @@ jobs:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-ocr-api
tags: |
type=semver,pattern={{version}}
type=semver,pattern={{version}},value=${{ env.VERSION }}
- name: Lowercase the repo name
run: echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV}
- name: Build and push Docker image
id: push
uses: docker/build-push-action@v6
with:
context: ./OCR/
file: ./OCR/Dockerfile
push: true
tags: ghcr.io/${{ env.IMAGE_NAME }}:${{ env.VERSION }}
tags: ghcr.io/${{ env.REPO }}:${{ env.VERSION }}
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v1
with:
Expand All @@ -64,5 +58,5 @@ jobs:
with:
app-name: reportvision-ocr-api-dev
publish-profile: ${{ secrets.AZURE_WEBAPP_PUBLISH_PROFILE }}
images: 'ghcr.io/${{ env.IMAGE_NAME }}:${{ env.VERSION }}'
images: 'ghcr.io/${{ env.REPO}}:${{ env.VERSION }}'

0 comments on commit dfaabbf

Please sign in to comment.