Repository navigation
feat(cli): kates deploy installs Kates standalone or under the Kates operator - #677
Merged
Merged
Conversation
…operator --kates-mode picks how deploy installs the Kates API: - standalone (default, unchanged): the kates chart with its own PostgreSQL. - operator: the Kates operator (operator/chart, or the published kates-operator chart), a PostgreSQL for Kates (the kates-db release of charts/cdc-postgresql, open to the Kates pods alone, or an existing Secret named by --kates-db-secret), and a Kates resource named kates that the operator runs as one member or, with --kates-replicas 3 or 5, a quorum. The Service stays kates and the key stays in Secret kates-api-key, so kates ports, health and the context key work in either mode. --operator-ns places the operator (a scope flag, so clean and status take it too). The wizard asks the mode after the components, then the members, namespace and database. Passwords go to Helm through a 0600 values file and to kubectl on stdin, never on a command line. Deploy refuses to install one mode over the other, and refuses operator mode with --adminless. When the Kates resource does not get Ready it prints the operator's reason. The component table gains kates-operator, kates-db and the Kates CRD group, so the plan, clean and status cover them; clean deletes the Kates resource while the operator still runs. Release builds now carry the kates-operator chart version, deploy checks that chart against publish-operator.yml's signature, and publish-operator.yml attests the chart's build provenance.
Owner
Author
|
The live run on the three-node Kind cluster is now finished, picking up from the description's "Not proven" section:
Still not run: |
aScheduledRunStoresItsReportOnce evaluated an every-minute schedule at now + 61 s and 10 s later. With now past second 49, the second tick fell in the next minute, whose due time rightly ran too: "execute wanted 1 time, was 2", about one run in six. Both ticks now sit in the minute after now's.
bmscomp
added a commit
that referenced
this pull request
Nov 16, 2026
Chart and appVersion 0.3.0, and the README's install, verify and pull commands on it. The chart description drops the run kinds 0.3.0 removes (#675), and the CronJob example pins kates-tester 1.41.0. 0.2.0 was published before publish-operator.yml attested the chart (#677), so kates deploy --kates-mode operator refuses it; 0.3.0 is pushed, signed and attested.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
kates deploy --kates-mode standalone|operator, configurable by flag and in the wizard.Modes
standalone(default, unchanged)operatorkateschartKatesresource namedkateskates-db, thecharts/cdc-postgresqlchart, open to the Kates pods alone; or--kates-db-secret <Secret with url, username, password>--kates-replicas 1,3or5--operator-ns(defaultkates-operator)What stays the same: the Service is
katesand the key is in Secretkates-api-keyin both modes, sokates ports,kates healthand the context key behave identically.Wizard: asks the mode right after the components, then the members, the operator namespace and an optional database Secret.
Pieces
kates-operatorandkates-dbare new components in the deploy graph.Katesresource with the chart's Kafka settings and chaos/topology targets. It sets replication 1 on one broker, as standalone does.pkg/componentslists both new releases and theKatesCRD group, so the plan,kates clean(resources deleted while the operator still runs, operator uninstalled last) andkates deploy statuscover them.--verbosecan't print them.--adminlessis refused.--kates-replicas/--kates-db-secretwithout operator mode are refused, and replicas other than 1/3/5.Katesresource that isn't Ready makes deploy print the operator's reason, not a bare timeout.release.ymladdsoperator/charttoChartVersions.kates-operatoronly in operator mode, including when the wizard picks it after the first pull.publish-operator.yml@refs/tags/operator-v*.publish-operator.ymlnow attests the chart's provenance, which deploy requires. The first operator release with the attestation (0.3.0) must come before the Kates release whose CLI pulls it.Proof
Unit tests:
Katesmanifest;kates-dbkeeps its password and never puts it on the command line; theKatesinstall with an existing key and--kates-db-secret; a missing DB Secret named; the mode-switch guard; the per-chart signer; the not-Ready reason.ChartVersionsand the mirror table.go test ./...green. golangci-lint shows only the two existingmcp_test.goerrcheck findings.On a fresh three-node Kind cluster:
kates-operator, watchingkates.kates-dbcame up, and theKatesresource was applied with 3 members, spread over 3 nodes.--create-namespace, so that namespace is now on deploy's namespace list.Not proven end to end:
kates:native-localimage (2026-10-25, before the quorum existed), so no leader could be elected.--kates-replicas 1wasn't done.Known, outside this PR:
config/cluster.yamlkeeps the control-plane taint, which leaves two Kafka pods Pending in any mode.katestests).