-
Notifications
You must be signed in to change notification settings - Fork 1
59 lines (55 loc) · 2.43 KB
/
call-update-core-fluent-bit-schemas.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
---
name: Reusable workflow to generate schemas for Calyptia Core Fluent Bit images
on:
workflow_call:
secrets:
token:
description: The Github token or similar to authenticate with.
required: true
jobs:
update-image-indexes:
name: Raise PR with the updated indexes.
runs-on: ubuntu-latest
permissions:
contents: none
outputs:
pr-number: ${{ steps.cpr.outputs.pull-request-number }}
pr-url: ${{ steps.cpr.outputs.pull-request-url }}
steps:
- name: Checkout core-images-index repo
uses: actions/checkout@v4
with:
token: ${{ secrets.token }}
repository: chronosphereio/calyptia-core-index
- name: Generate indexes and schemas
run: |
scripts/create-container-index.sh
scripts/create-core-fluent-bit-schemas.sh
shell: bash
env:
GITHUB_TOKEN: ${{ secrets.token }}
- name: Push to PR on index repo
id: cpr
uses: peter-evans/create-pull-request@v7
with:
commit-message: 'ci: add core container images index'
signoff: true
branch: ci_update_container_index
delete-branch: true
title: 'ci: update core container images index'
token: ${{ secrets.token }}
labels: ci,automerge
add-paths: |
*index.json
*core-fluent-bit*.json
body: |
Update indexes and schemas
- Created by ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
- Auto-generated by create-pull-request: https://github.com/peter-evans/create-pull-request
draft: false
- name: Check outputs
if: ${{ steps.cpr.outputs.pull-request-number }}
run: |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
shell: bash