diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4c3628c..e1fce1f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1419,6 +1419,46 @@ "SSH_KEY": "${{ secrets.DEPLOY_KEY }}" "if": "steps.filter.outputs.workflows == 'true'" "run": "make libs/grafana-agent" + "grafana-alloy": + "name": "Generate grafana-alloy Jsonnet library and docs" + "needs": + - "build" + - "repos" + "runs-on": "ubuntu-latest" + "steps": + - "uses": "actions/checkout@v4" + - "id": "filter" + "uses": "dorny/paths-filter@v3" + "with": + "filters": | + workflows: + - '.github/**' + - 'bin/**' + - 'Dockerfile' + - 'go.mod' + - 'go.sum' + - 'jsonnet/**' + - 'main.go' + - 'Makefile' + - 'pkg/**' + - 'scripts/**' + - 'tf/**' + - 'libs/grafana-alloy/**' + - "if": "steps.filter.outputs.workflows == 'true'" + "uses": "actions/download-artifact@v4" + "with": + "name": "docker-artifact" + "path": "artifacts" + - "if": "steps.filter.outputs.workflows == 'true'" + "run": "make load" + - "env": + "DIFF": "true" + "GEN_COMMIT": "${{ github.ref == 'refs/heads/master' && github.repository == 'jsonnet-libs/k8s' }}" + "GIT_COMMITTER_EMAIL": "86770550+jsonnet-libs-bot@users.noreply.github.com" + "GIT_COMMITTER_NAME": "jsonnet-libs-bot" + "SSH_KEY": "${{ secrets.DEPLOY_KEY }}" + "if": "steps.filter.outputs.workflows == 'true'" + "run": "make libs/grafana-alloy" "grafana-operator": "name": "Generate grafana-operator Jsonnet library and docs" "needs": @@ -2413,6 +2453,7 @@ - "gateway-api" - "google-cloud-sql-proxy-operator" - "grafana-agent" + - "grafana-alloy" - "grafana-operator" - "harbor-operator" - "istio" diff --git a/libs/grafana-alloy/config.jsonnet b/libs/grafana-alloy/config.jsonnet new file mode 100644 index 0000000..095bcf8 --- /dev/null +++ b/libs/grafana-alloy/config.jsonnet @@ -0,0 +1,21 @@ +local config = import 'jsonnet/config.jsonnet'; + +local versions = [ + { output: '1.6', version: '1.6.1' }, +]; + +config.new( + name='grafana-alloy', + specs=[ + { + local url = 'https://raw.githubusercontent.com/grafana/alloy/refs/tags/v%s/operations/helm/charts/alloy/charts/crds/crds' % v.version, + output: v.output, + prefix: '^com\\.grafana\\..*', + crds: [ + '%s/monitoring.grafana.com_podlogs.yaml' % url, + ], + localName: 'grafana-alloy', + } + for v in versions + ] +)