Repository navigation
service-vault: bootstrap vault CA and expose vault via TCP gateway for relays - #1357
Open
ArnobKumarSaha wants to merge 1 commit into
Open
ArnobKumarSaha wants to merge 1 commit into
ArnobKumarSaha wants to merge 1 commit into
Conversation
ArnobKumarSaha
force-pushed
the
master
branch
from
November 17, 2026 16:43
2a1f884 to
f833307
Compare
…r relays - Bootstrap a CA (selfSigned Issuer -> isCA Certificate -> CA Issuer) when vaultServer.tls.caSecretName is empty; previously the issuer pointed at a vault-ca secret nothing created, so vault TLS certs were never issued. - Add vaultServer.serverAddress, emitted as the kubevault.com/server-address annotation and as a server cert SAN; akp-installer (and the generated ace-installer) defaults it to platform.host. Without it the VaultServer validating webhook rejects every update when relayPlacementRef is set on a ClusterIP service. - Emit relayPlacementRef/relayTemplate only when relay.clusterSet is set, and fail at template time if relay is on without LoadBalancer or serverAddress. - Replace the HTTPS-terminating Gateway (referenced a missing service-vault-cert secret) with TCP passthrough on 8200 and 50053 so spokes reach vault with its own CA-signed cert. Signed-off-by: Arnob kumar saha <arnob@appscode.com>
ArnobKumarSaha
force-pushed
the
arnob-vault-ca-fix
branch
from
December 2, 2026 09:08
65309fd to
6220433
Compare
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.
Problem
On a fresh ACE install (chart v2026.9.11, kubevault operator v0.25.0) the
kubevault/vaultVaultServer never gets pods:spec.relayPlacementRef requires a "vault" service template of type: LoadBalancer or the "kubevault.com/server-address" annotation set to an externally-resolvable addressThe chart always emits
relayPlacementRef, but defaults toserviceType: ClusterIPwith no annotation.service-vault-ca-issueris a CA Issuer on secretvault-ca, and nothing creates that secret (ErrGetKeyPair: secrets "vault-ca" not found), so vault TLS certs are never issued.vaultGateway terminates HTTPS withservice-vault-cert, which also doesn't exist (InvalidCertificateRef). Even with the cert, spokes would get a cert that the hub CA bundle doesn't validate.Changes
vaultServer.tls.caSecretNameis empty (new default), the chart creates a selfSigned Issuer, anisCACertificate (<fullname>-ca,rotationPolicy: Never), and a CA Issuer. A user-suppliedcaSecretNameis still honored.vaultServer.serverAddress(new): emitted as thekubevault.com/server-addressannotation and as aservercert SAN (IP or DNS). The operator only adds LoadBalancer ingress to SANs, not this annotation. akp-installer defaults it toplatform.host; the generatedace-installerandakp-installer-certifiedcarry the same default.relayPlacementRef/relayTemplateare emitted only whenrelay.clusterSetis set. Rendering fails early if relay is on withoutserviceType: LoadBalancerorserverAddress.ace-natsTCPRoute pattern. Rendered only whenserverAddressis set.Testing
helm templatechecked for: defaults (fails with the guard message),serverAddressas an IP and as a DNS name, relay off with a custom CA, andserviceType=LoadBalancer.kubectl apply --dry-run=serveron the live cluster: the VaultServer update is accepted by the webhook, and the Gateway, TCPRoutes, Certificate and Issuers validate.make gen,make fmt,go build ./...pass.Upgrade note
The CA secret name changes from
vault-cato<fullname>-ca. On existing installsvault-canever existed, so nothing is lost.