Skip to content

Commit

Permalink
Add Grafana Agent (jsonnet-libs#93)
Browse files Browse the repository at this point in the history
  • Loading branch information
andersosthus authored Nov 16, 2021
1 parent d128fa2 commit a1206c6
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,19 @@
"GIT_COMMITTER_NAME": "jsonnet-libs-bot"
"SSH_KEY": "${{ secrets.DEPLOY_KEY }}"
"run": "make build libs/fluxcd"
"grafana-agent":
"name": "Generate grafana-agent Jsonnet library and docs"
"needs": "repos"
"runs-on": "ubuntu-latest"
"steps":
- "uses": "actions/checkout@v2"
- "env":
"DIFF": "true"
"GEN_COMMIT": "${{ github.ref == 'refs/heads/master' && github.repository == 'jsonnet-libs/k8s' }}"
"GIT_COMMITTER_EMAIL": "[email protected]"
"GIT_COMMITTER_NAME": "jsonnet-libs-bot"
"SSH_KEY": "${{ secrets.DEPLOY_KEY }}"
"run": "make build libs/grafana-agent"
"istio":
"name": "Generate istio Jsonnet library and docs"
"needs": "repos"
Expand Down Expand Up @@ -239,6 +252,7 @@
- "eck-operator"
- "flagger"
- "fluxcd"
- "grafana-agent"
- "istio"
- "k8s"
- "kube-prometheus"
Expand Down
24 changes: 24 additions & 0 deletions libs/grafana-agent/config.jsonnet
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
local config = import 'jsonnet/config.jsonnet';

local versions = [
{output: '0.20', version:'0.20.0'}
];

config.new(
name='grafana-agent',
specs=[
{
local url = 'https://raw.githubusercontent.com/grafana/agent/v%s/production/operator/crds' % v.version,
output: v.output,
prefix: '^com\\.grafana\\..*',
crds: [
'%s/monitoring.grafana.com_grafanaagents.yaml' % url,
'%s/monitoring.grafana.com_logsinstances.yaml' % url,
'%s/monitoring.grafana.com_metricsinstances.yaml' % url,
'%s/monitoring.grafana.com_podlogs.yaml' % url,
],
localName: 'grafana-agent',
}
for v in versions
]
)

0 comments on commit a1206c6

Please sign in to comment.