refactor: remove dead Vault integration and unused structured API code#17
Merged
Conversation
Remove code that is incompatible with the one-way cluster architecture (clusters are not publicly accessible; Flux pulls from GitHub only): Vault Helm templates (vault-pki.yaml, vault-static.yaml): Created VaultPKISecret/VaultStaticSecret CRs requiring cluster→Vault communication, which is not possible in this architecture. Vault values and deployment conditionals: Removed vault.* values block and vault.enabled conditional in the deployment volume section. Static TLS certs now always come from the haproxy-operator-tls Secret when SPIRE is disabled. Structured Dataplane API methods (dataplane_client.go): ApplyConfiguration, applyBackend, applyServer, applyFrontend, applyBind, applyBackendSwitchRule, and all *Exists helpers were never called — the reconciler exclusively uses raw config push via ApplyRawConfiguration/ApplyRawConfigurationValidated. Dead types (types.go): Config, Backend, Server, Frontend, Bind, UseBackendRule structs and HashConfig function — only referenced by the removed methods. Production code uses config.HashBytes() instead of HashConfig. README updated to reflect one-way architecture and two supported auth paths (SPIRE mTLS or static TLS certs). Co-Authored-By: kyle_hunter@bcit.ca <kyle_hunter@bcit.ca>
Contributor
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
⚙️ Control Options:
|
doRequestVersioned was only called by the structured API methods removed in the previous commit. isNotFound was only called by the *Exists helpers (also removed). Remove both and their tests. Co-Authored-By: kyle_hunter@bcit.ca <kyle_hunter@bcit.ca>
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.
Summary
Removes code that is incompatible with the one-way cluster architecture (clusters are not publicly accessible; Flux pulls from GitHub, no direct cluster-to-external communication).
Removed:
charts/templates/vault-pki.yamlcharts/templates/vault-static.yamlvault.*values blockvault.enabledconditional indeployment.yamlhaproxy-operator-tlsSecretApplyConfiguration,applyBackend,applyServer,applyFrontend,applyBind,applyBackendSwitchRule,*Existshelperstypes.go(Config,Backend,Server,Frontend,Bind,UseBackendRule,HashConfig)config.HashBytes()Updated:
values.yamlcomment: Clarifies cert paths are for static TLS (when SPIRE is disabled)All tests pass (
go test -race ./...),go vetclean,helm lintclean.Review & Testing Checklist for Human
flux-fleetbasehelmrelease.yamlremovesvault.enabled: truebefore deploying (addressed in flux-fleet#27)Notes
Companion PRs:
vault.enabled: truefrom HelmRelease, fixes notifications event source, enables haproxy-operator on cluster03Link to Devin session: https://app.devin.ai/sessions/40f980f21cd648f3b53ef45b06451a7e
Requested by: @kphunter