-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add grafana annotation workflow (#175)
- Loading branch information
1 parent
e523dd4
commit d4c7a64
Showing
1 changed file
with
47 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: grafana annotation | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
environment: | ||
description: Environment | ||
required: false | ||
type: string | ||
grafanaAnnotationTags: | ||
description: Custom annotation tags | ||
required: false | ||
type: string | ||
grafanaAnnotationText: | ||
description: Custom annotation text | ||
required: true | ||
type: string | ||
grafanaAnnotationId: | ||
description: Annotation Id | ||
required: false | ||
type: string | ||
|
||
secrets: | ||
grafanaApiToken: | ||
description: Grafana API token | ||
required: true | ||
|
||
outputs: | ||
annotation_id: | ||
description: Annotation Id | ||
value: ${{ jobs.grafana.outputs.annotation_id }} | ||
|
||
jobs: | ||
grafana: | ||
runs-on: ubuntu-latest | ||
outputs: | ||
annotation_id: ${{ steps.grafana.outputs.annotation-id }} | ||
steps: | ||
- name: add Grafana annotation | ||
id: grafana | ||
uses: hexionas/[email protected] | ||
with: | ||
grafanaHost: "https://grafana.apify.dev" | ||
grafanaToken: ${{ secrets.grafanaApiToken }} | ||
grafanaText: ${{ inputs.grafanaAnnotationText }} | ||
grafanaTags: ${{ inputs.grafanaAnnotationTags }} | ||
grafanaAnnotationID: ${{ inputs.grafanaAnnotationId }} |