-
Notifications
You must be signed in to change notification settings - Fork 456
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
15 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,12 +5,15 @@ on: | |
workflow_dispatch: | ||
schedule: | ||
- cron: '0 1 * * 1-5' | ||
issue_comment: | ||
types: ['created'] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
bump-elastic-stack: | ||
if: ${{ github.event_name != 'issue_comment' || (github.event.issue.pull_request && contains(github.event.comment.body, '/test bump-stack')) }} | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
|
@@ -23,14 +26,24 @@ jobs: | |
- name: Install Updatecli in the runner | ||
uses: updatecli/[email protected] # updatecli v0.80.0 | ||
|
||
- name: Select diff action | ||
if: ${{ github.event_name == 'issue_comment' }} | ||
run: | | ||
echo "UPDATECLI_ACTION=diff" >> $GITHUB_ENV | ||
- name: Select apply action | ||
if: ${{ github.event_name != 'issue_comment' }} | ||
run: | | ||
echo "UPDATECLI_ACTION=apply" >> $GITHUB_ENV | ||
- name: Update latest testing 7.x stack version | ||
# --experimental needed for commitusingapi option. | ||
run: updatecli --experimental apply --config .github/workflows/updatecli.d/bump-latest-7x-version.yml --values .github/workflows/updatecli.d/scm.yml | ||
run: updatecli --experimental ${{ env.UPDATECLI_ACTION }} --config .github/workflows/updatecli.d/bump-latest-7x-version.yml --values .github/workflows/updatecli.d/scm.yml | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Update latest testing stack version | ||
# --experimental needed for commitusingapi option. | ||
run: updatecli --experimental apply --config .github/workflows/updatecli.d/bump-latest-snapshot-version.yml --values .github/workflows/updatecli.d/scm.yml | ||
run: updatecli --experimental ${{ env.UPDATECLI_ACTION }} --config .github/workflows/updatecli.d/bump-latest-snapshot-version.yml --values .github/workflows/updatecli.d/scm.yml | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |