Add concurrency & schedule for ci-snapshot.yml

* No need in queued snapshot builds: the latest is enough
* Build fresh snapshot every night
This commit is contained in:
Artem Bilan
2024-01-02 14:33:59 -05:00
parent 0e574aad1c
commit 6cc91b5b73

View File

@@ -2,14 +2,24 @@ name: CI SNAPSHOT
on:
workflow_dispatch:
push:
branches:
- main
- '*.x'
schedule:
- cron: '0 5 * * *'
concurrency:
group: group-snapshot-for-${{ github.ref }}
cancel-in-progress: true
jobs:
build-snapshot:
uses: spring-io/spring-github-workflows/.github/workflows/spring-artifactory-gradle-snapshot.yml@v1
with:
gradleTasks: ${{ github.event_name == 'schedule' && '--rerun-tasks' || '' }}
secrets:
GRADLE_ENTERPRISE_CACHE_USER: ${{ secrets.GRADLE_ENTERPRISE_CACHE_USER }}
GRADLE_ENTERPRISE_CACHE_PASSWORD: ${{ secrets.GRADLE_ENTERPRISE_CACHE_PASSWORD }}