From b2920b95315c907dfcf3b1722c2f831957b1738f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josef=20Kol=C3=A1=C5=99?= Date: Wed, 5 Nov 2025 14:12:50 +0100 Subject: [PATCH] feat: add nats support --- .github/workflows/main.yml | 41 ++++++++++++++++++++++++++++++++++++++ libs/nats/config.jsonnet | 17 ++++++++++++++++ 2 files changed, 58 insertions(+) create mode 100644 libs/nats/config.jsonnet diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 09b3b79..dbff560 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -2339,6 +2339,46 @@ "SSH_KEY": "${{ secrets.DEPLOY_KEY }}" "if": "steps.filter.outputs.workflows == 'true'" "run": "make libs/mysql-operator" + "nats": + "name": "Generate nats 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/nats/**' + - "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/nats" "openshift": "name": "Generate openshift Jsonnet library and docs" "needs": @@ -2636,6 +2676,7 @@ - "milvus-operator" - "minio-operator" - "mysql-operator" + - "nats" - "openshift" - "prometheus-operator" - "pyrra" diff --git a/libs/nats/config.jsonnet b/libs/nats/config.jsonnet new file mode 100644 index 0000000..eead393 --- /dev/null +++ b/libs/nats/config.jsonnet @@ -0,0 +1,17 @@ +local config = import 'jsonnet/config.jsonnet'; +local versions = [ + { version: '0.20', tag: 'v0.20.1' }, +]; + +config.new( + name='nats', + specs=[ + { + output: v.version, + prefix: '^io\\.nats\\.jetstream\\..*', + crds: ['https://github.com/nats-io/nack/releases/download/%(tag)s/crds.yml' % { tag: v.tag }], + localName: 'nats', + } + for v in versions + ] +)