Skip to content

Commit

Permalink
push every 15 days
Browse files Browse the repository at this point in the history
Signed-off-by: Oguz Ozturk <[email protected]>
  • Loading branch information
oguzkaganozt committed Jun 24, 2024
1 parent 991afca commit 3423d0d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
5 changes: 2 additions & 3 deletions .github/actions/docker-build-and-push/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ inputs:
required: false
allow-push:
description: ""
default: "true"
default: "false"
required: false

runs:
Expand Down Expand Up @@ -108,8 +108,7 @@ runs:
password: ${{ github.token }}

- name: Build and Push to GitHub Container Registry
if: ${{ github.event_name == 'push' ||
github.event_name == 'schedule' ||
if: ${{ github.event_name == 'schedule' ||
(github.event_name == 'workflow_dispatch' && github.event.inputs.artifacts-destination == 'registry') }}
uses: docker/bake-action@v5
with:
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/docker-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,11 @@ jobs:
additional-tag-suffix: -cuda
steps:
- name: Check if push day
if: ${{ github.event_name == 'schedule' }}
run: |
if [ $(date +'%d') -eq 01 ] || [ $(date +'%d') -eq 15 ]; then echo "IS_PUSH_DAY=true" >> $GITHUB_ENV; else echo "IS_PUSH_DAY=false" >> $GITHUB_ENV; fi
if: ${{ github.event_name == 'schedule' }}

echo "Day of the month: $(date +'%d')"
- name: Check out repository
uses: actions/checkout@v4

Expand Down

0 comments on commit 3423d0d

Please sign in to comment.