{"id":13742721,"url":"https://github.com/fintechstudios/ververica-platform-k8s-operator","last_synced_at":"2026-03-06T18:24:43.590Z","repository":{"id":36684493,"uuid":"197781537","full_name":"fintechstudios/ververica-platform-k8s-operator","owner":"fintechstudios","description":"Kubernetes Operator for the Ververica Platform","archived":false,"fork":false,"pushed_at":"2023-01-19T09:31:45.000Z","size":914,"stargazers_count":34,"open_issues_count":25,"forks_count":13,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-05-22T14:32:30.679Z","etag":null,"topics":["crds","golang","helm","k8s","k8s-controller","k8s-operator","ververica-platform"],"latest_commit_sha":null,"homepage":"https://flink-packages.org/packages/ververica-platform-k8s-operator","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fintechstudios.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":"CODEOWNERS","security":null,"support":null}},"created_at":"2019-07-19T13:55:36.000Z","updated_at":"2024-02-26T06:06:21.000Z","dependencies_parsed_at":"2023-02-10T22:01:29.561Z","dependency_job_id":null,"html_url":"https://github.com/fintechstudios/ververica-platform-k8s-operator","commit_stats":null,"previous_names":["fintechstudios/ververica-platform-k8s-controller"],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fintechstudios%2Fververica-platform-k8s-operator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fintechstudios%2Fververica-platform-k8s-operator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fintechstudios%2Fververica-platform-k8s-operator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fintechstudios%2Fververica-platform-k8s-operator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fintechstudios","download_url":"https://codeload.github.com/fintechstudios/ververica-platform-k8s-operator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253170990,"owners_count":21865274,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crds","golang","helm","k8s","k8s-controller","k8s-operator","ververica-platform"],"created_at":"2024-08-03T05:00:35.400Z","updated_at":"2026-03-06T18:24:38.084Z","avatar_url":"https://github.com/fintechstudios.png","language":"Go","funding_links":[],"categories":["Repository is obsolete"],"sub_categories":["Awesome Operators in the Wild"],"readme":"# Ververica Platform K8s Operator\n\n[![go reportcard](https://goreportcard.com/badge/github.com/fintechstudios/ververica-platform-k8s-operator)](https://goreportcard.com/report/github.com/fintechstudios/ververica-platform-k8s-operator)\n[![FOSSA Status](https://app.fossa.io/api/projects/custom%2B12442%2Fgit%40github.com%3Afintechstudios%2Fververica-platform-k8s-operator.git.svg?type=shield)](https://app.fossa.io/projects/custom%2B12442%2Fgit%40github.com%3Afintechstudios%2Fververica-platform-k8s-operator.git?ref=badge_shield)[![pipeline status](https://gitlab.com/fintechstudios/ververica-platform-k8s-operator/badges/master/pipeline.svg)](https://gitlab.com/fintechstudios/ververica-platform-k8s-operator/commits/master)\n[![coverage report](https://gitlab.com/fintechstudios/ververica-platform-k8s-operator/badges/master/coverage.svg)](https://gitlab.com/fintechstudios/ververica-platform-k8s-operator/commits/master)\n\nMakes Ververica Platform resources Kubernetes-Native! Defines CustomResourceDefinitions\nfor mapping resources to K8s!\n\nBuilt for Ververica Platform version `2.x`.\n\n[More about the Ververica Platform](https://www.ververica.com/platform-overview)  \n[Ververica Platform Docs](https://docs.ververica.com/)\n\n## Supported Resources\n\nSince the resources names of K8s and the Ververica Platform somewhat clash, the \ncustom VP Resources will all be prefixed with `Vp`.\n\n* `DeploymentTarget` -\u003e `VpDeploymentTarget`\n* `Deployment` -\u003e `VpDeployment`\n* `Namespace` -\u003e `VpNamespace`\n* `Savepoint` -\u003e `VpSavepoint`\n* `Event` -\u003e native K8s `Event`\n\n## Unsupported\n\n* `Job`\n* `DeploymentDefaults`\n* `Secret Value`\n* `Status`\n\nTo avoid naming conflicts, and for simplicity, and VP `metadata` and `spec` fields\nare nested under the top-level `spec` field of the K8s resource.\n\nLook in [docs/mappings](docs/mappings) for information on each supported resource.\n\n## Getting Started\n\nPlease have a look at the [`docs`](docs/README.md) for information on getting started using\nthe operator.\n\n### Editions\n\nThis operator works with both the Community and Enterprise editions of the Ververica Platform, with the caveats:\n* `VpNamespaces` are not supported by the Community Edition, so the manager will not register those resources\n* The `spec.metadata.namespace` field must either be left unset or set explicitly to `default` for all `Vp` resources\n\nFind out more about [the editions here](https://www.ververica.com/pricing-editions).\n\n## Running\n\nTo run the binary directly, after building run `./bin/manager`.\n\n**Flags:**\n* `--help` prints usage\n* `--vvp-url=http://localhost:8081` the url, without trailing slash, for the Ververica Platform\n* `--vvp-edition=enterprise` the Ververica Platform Edition to support. See [Editions](#Editions) for more.\n* `--debug` debug mode for logging\n* `--enable-leader-election` to ensure only one manager is active with a multi-replica deployment\n* `--metrics-addr=:8080` address to bind metrics to \n* `--watch-namespace=all-namespaces` the namespace to watch resources on\n* `[--env-file]` the path to an environment (`.env`) file to be loaded\n\nFor authorization with the AppManager's API, a token is needed. This can be provided in the environment on either a\nper-namespace or one-token-to-rule-them-all basis. If it is not provided in the environment, an \"owner\" token will be created\nfor each namespace that resources are managed in.\n\nSpecifying in the environment is a good way to integrate with namespaces that aren't defined in Kubernetes.\n\n**Environment:**\n* `APPMANAGER_API_TOKEN_{NAMESPACE}` a token to use for resources in a specific Ververica Platform namespace, upper-cased\n* `APPMANAGER_API_TOKEN` if no namespace-specific token can be found, this value will be used. \n\n## Docker\n\nImages are published to [Docker Hub](https://hub.docker.com/r/fintechstudios/ververica-platform-k8s-operator).\n*  The `latest` tag always refers to the current HEAD in the master branch.\n* Each master commit hash is also tagged and published.\n* Git tags are published with the same tag. \n\n## Helm\n\nA Helm chart for the operator lives in [`./charts/vp-k8s-operator`](charts/vp-k8s-operator),\nwhich sets up a deployment with a metrics server, RBAC policies, CRDs, and, optionally,\nan RBAC proxy for the metrics over HTTPS.\n\nThe CRDs are managed in a separate chart ([`./charts/vp-k8s-operator-crds`](charts/vp-k8s-operator-crds)), which also\nneeds to be installed.\n\n## Development\n\nBuilt using [`kubebuilder`](https://github.com/kubernetes-sigs/kubebuilder).\n[`kind`](https://github.com/kubernetes-sigs/kind) is used for running a local test cluster,\nthough something like `minikube` will also do.  \n\nMore on the design of the controller and its resources can be found\nin [docs/design.md](docs/design.md).\n\nAlso built as a Go module - no vendor files here.\n\nSystem Pre-requisites:\n- `go` \u003e= `1.14.x`\n- `make` \u003e= `4`\n- `kubebuilder` == [`v2.2.0`](https://github.com/kubernetes-sigs/kubebuilder/releases/tag/v2.2.0)\n- `docker` \u003e= `19`\n- `kind` \u003e= `0.6.0`\n\n### `make` Scripts\n\n- `make` alias for `manager`\n- `make manager` builds the entire app binary\n- `make run` runs the entire app locally\n- `make manifests` builds the CRDs from `./config/crd`\n- `make install` installs the CRDs from `./config/crd` on the cluster\n- `make deploy` installs the entire app on the cluster\n- `make docker-build` builds the docker image\n- `make docker-push` pushes the built docker image\n- `make generate` generates the controller code from the `./api` package\n- `make swagger-gen` generates the swagger code\n- `make lint` runs linting on the source code\n- `make fmt` runs `go fmt` on the package\n- `make test` runs the test suites with coverage\n- `make patch-image` sets the current version as the default deployment image tag\n- `make kustomize-build` builds the default k8s resources for deployment\n\n#### For working with a local kind cluster\n\n- `make test-cluster-create` initializes a cluster for testing, using kind\n- `make test-cluster-delete` deletes the testing cluster\n- `make test-cluster-setup` installs cert-manager, the Community VVP, the vp-k8s-crds, and the vp-k8s-operator on the test cluster\n- `make test-cluster-instal-chart` builds the operator and installs it on the test cluster from the local chart\n- `make test-cluster-instal-crds` installs the vp-k8s-operator CRDs on the test cluster from the local chart\n\n### Environment\n\nTo use the default test cluster, you'll need to store a `KUBECONFIG` env var pointed to it.\n\n[`godotenv`](https://github.com/joho/godotenv) automatically loads this when running `main`.\n\n### AppManager + Platform APIs\n\nThe API Clients are auto-generated using the [Swagger Codegen utility](https://github.com/swagger-api/swagger-codegen.git).\n\n#### AppManager\n\nThe [`appmanager-api` Swagger file](appmanager-api-swagger.json) is from the live API documentation (available at `${VP_URL}/api/swagger`),\nbut the generated client needs a few updates to work correctly.\n\n##### Post-Generation Changes\n\nThe `optional` package is missing from many of the imports in the generated code, as must be added manually.\n\n```go\npackage ververicaplatformapi\n\nimport (\n\t// ...\n    \"github.com/antihax/optional\"\n    // ...\n)\n```\n\nAffected files:\n- `api_event_resource.go`\n- `api_job_resource.go`\n- `api_savepoint_resource.go`\n\n\nType Changes:\n* `model_pods.go` needs to be updated with the proper Kubernetes types\n* `model_volume_and_mount.go` needs to be updated with the proper Kubernetes types\n\n\nThere is also a bug that cannot handle an empty Swagger type to represent the `any` type, so\nyou must manually change [`model_any.go`](pkg/vvp/appmanager-api/model_any.go) to:\n\n```go\npackage appmanagerapi\n\ntype Any interface {}\n```\n\nYou'll also have to change any usages of this type in `structs` to be embedded, instead of by pointer ref, namely in:\n- `model_json_patch_generic.go`\n\n\n### Building Images\n\nThe images are built in two steps:\n1. The [`build.Dockerfile`](build.Dockerfile) image is a full development environment for running tests, linting,\nand building the source with the correct tooling. This can also be used for development if you so like,\njust override the entrypoint.\n2. The build image is then passed as a build arg to the main [`Dockerfile`](Dockerfile), which builds\nthe manager binary and copies it over into an image for distribution.\n\n\n## Acknowledgements\n\nOther OSS that influenced this project:\n* [Kong Ingress Controller](https://github.com/Kong/kubernetes-ingress-controller)\n\n## License\n\n[Licensed under Apache 2.0](LICENSE)\n\n[![FOSSA Status](https://app.fossa.io/api/projects/custom%2B12442%2Fgit%40github.com%3Afintechstudios%2Fververica-platform-k8s-operator.git.svg?type=large)](https://app.fossa.io/projects/custom%2B12442%2Fgit%40github.com%3Afintechstudios%2Fververica-platform-k8s-operator.git?ref=badge_large)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffintechstudios%2Fververica-platform-k8s-operator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffintechstudios%2Fververica-platform-k8s-operator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffintechstudios%2Fververica-platform-k8s-operator/lists"}