Skip to content

Commit

Permalink
fix(docker): Enable push on schedule event
Browse files Browse the repository at this point in the history
To reduce the frequency of docker builds, on
commit e3bbcdb the workflow moved from push based to
schedule based. The registry publishing
was attached to push and worflow_dispatch events,
therefore, any schedule event was ignored.

Since builds now happens once a day and in case of version tag,
registry publish is now set to be valid on all build cases.

For extended image, the time schedule set was removed and only when
runtime main docker workflow has their build complete triggers the
extended workflow using wokrflow_run dependency.

Signed-off-by: Helio Chissini de Castro <[email protected]>
  • Loading branch information
heliocastro committed Oct 8, 2023
1 parent 313d877 commit 0de9d53
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
15 changes: 1 addition & 14 deletions .github/workflows/docker-ort-runtime-ext.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,6 @@ name: Docker extended runtime image

on:
workflow_dispatch:
schedule:
- cron: '0 4 * * *'
pull_request:
paths:
- '.versions'
- 'Dockerfile'
- 'Dockerfile-extended'
- '.github/workflows/docker-ort-runtime.yml'
- '.github/workflows/docker-ort-runtime-ext.yml'
push:
tags:
- '*'
workflow_run:
workflows:
- 'Docker runtime image'
Expand Down Expand Up @@ -153,7 +141,6 @@ jobs:
SWIFT_VERSION=${{ env.SWIFT_VERSION }}
runtime_extended_image:
if: ${{ github.event_name == 'push' || github.event_name == 'workflow_dispatch' }}
name: Build ORT extended image
needs: [ android_image, dart_image, dotnet_image, haskell_image, scala_image, swift_image ]
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -198,7 +185,7 @@ jobs:
with:
context: .
file: Dockerfile-extended
push: ${{ github.event_name == 'push' || github.event_name == 'workflow_dispatch' }}
push: true
load: false
tags: |
${{ steps.meta-ort.outputs.tags }}
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/docker-ort-runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,6 @@ jobs:
type=raw,value=${{ env.ORT_VERSION }}
- name: Build ORT runtime image
if: ${{ github.event_name == 'push' || github.event_name == 'workflow_dispatch' }}
uses: docker/build-push-action@v5
with:
context: .
Expand Down

0 comments on commit 0de9d53

Please sign in to comment.