From 0a17dc35db30aed8e2c3559f40123165c9c1eba8 Mon Sep 17 00:00:00 2001 From: Hemanth Bollamreddi Date: Sun, 18 Aug 2024 15:56:26 +0530 Subject: [PATCH] Add metallb CRDs --- .github/workflows/main.yml | 41 +++++++++++++++++++++++++++++++++++++ libs/metallb/config.jsonnet | 28 +++++++++++++++++++++++++ 2 files changed, 69 insertions(+) create mode 100644 libs/metallb/config.jsonnet diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index f21b036..e3fcbe7 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1899,6 +1899,46 @@ "SSH_KEY": "${{ secrets.DEPLOY_KEY }}" "if": "steps.filter.outputs.workflows == 'true'" "run": "make libs/litmus-chaos" + "metallb": + "name": "Generate metallb Jsonnet library and docs" + "needs": + - "build" + - "repos" + "runs-on": "ubuntu-latest" + "steps": + - "uses": "actions/checkout@v3" + - "id": "filter" + "uses": "dorny/paths-filter@v2" + "with": + "filters": | + workflows: + - '.github/**' + - 'bin/**' + - 'Dockerfile' + - 'go.mod' + - 'go.sum' + - 'jsonnet/**' + - 'main.go' + - 'Makefile' + - 'pkg/**' + - 'scripts/**' + - 'tf/**' + - 'libs/metallb/**' + - "if": "steps.filter.outputs.workflows == 'true'" + "uses": "actions/download-artifact@v2" + "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/metallb" "milvus-operator": "name": "Generate milvus-operator Jsonnet library and docs" "needs": @@ -2265,6 +2305,7 @@ - "kubevela" - "kyverno" - "litmus-chaos" + - "metallb" - "milvus-operator" - "minio-operator" - "mysql-operator" diff --git a/libs/metallb/config.jsonnet b/libs/metallb/config.jsonnet new file mode 100644 index 0000000..b846903 --- /dev/null +++ b/libs/metallb/config.jsonnet @@ -0,0 +1,28 @@ +local config = import 'jsonnet/config.jsonnet'; +local versions = ['0.14.8']; +local manifests = [ + 'bfdprofiles', + 'bgpadvertisements', + 'bgppeers', + 'communities', + 'ipaddresspools', + 'l2advertisements', + 'servicel2statuses', +]; + +config.new( + name='metallb', + specs=[ + { + localName: 'metallb', + output: std.join('.', std.split(version, '.')[:2]), + prefix: '^io\\.metallb\\..*', + crds: [ + 'https://raw.githubusercontent.com/metallb/metallb/v%s/config/crd/bases/metallb.io_%s.yaml' + % [version, manifest] + for manifest in manifests + ], + } + for version in versions + ] +)