Skip to content

Commit da55ed7

Browse files
authored
weekly and manually trigger integration test (#52)
* weekly and manually trigger integration test weekly schedule integration test does not push image to github; manually trigger integration test can push image by clicking checkbox. * Update integration-testing.yml * Update integration-testing.yml
1 parent b219983 commit da55ed7

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

.github/workflows/integration-testing.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,14 @@ name: Integration Testing
22
on:
33
push:
44
branches: [ main ]
5+
workflow_dispatch:
6+
inputs:
7+
push:
8+
description: 'Should workflow push sample app docker image'
9+
type: boolean
10+
required: true
11+
schedule:
12+
- cron: '0 11 * * Mon'
513

614
jobs:
715
publish_apps:
@@ -59,7 +67,10 @@ jobs:
5967
- name: Build and Push Docker image
6068
uses: docker/build-push-action@v2
6169
with:
62-
push: true
70+
push: ${{ github.event.inputs.push == 'true' ||
71+
github.event_name == 'schedule' ||
72+
( github.event_name == 'push' && github.ref == 'refs/heads/main' )
73+
}}
6374
context: ${{ env.APP_PATH }}
6475
tags: |
6576
${{ env.APP_IMAGE }}

0 commit comments

Comments
 (0)