cEOS: back RESTCONF with EOS's own SSL profile, dropping the cert Job - #18
Merged
Merged
Conversation
RESTCONF died on every container restart. The startup-config is a ConfigMap
and survives anything; the certificate it named was written by a Job into the
container's writable layer and did not. After a restart the profile referenced
a file that no longer existed, EOS marked it invalid, and the Job was long
since Complete and never re-ran:
Certificate 'restconf.crt' does not exist
Key 'restconf.key' does not exist
v0.5.10 fixed the ordering at install time. It could not fix this, because the
defect is not ordering -- it is that the config outlives the certificate it
points at.
EOS generates a self-signed profile for itself, so pointing RESTCONF at
ARISTA_DEFAULT_SELF_SIGNED_PROFILE removes the certificate from the chart's
concerns entirely. This is what `management api http-commands` already did:
eAPI names no profile, takes the EOS default, and is the reason eAPI on 443
kept working across restarts while RESTCONF did not. RESTCONF now behaves the
same way rather than through a mechanism of its own.
Verified from a cold boot with no Job in the cluster: the profile is already
valid when the config is applied, `show management api restconf` reports the
server running on 6020, and a real request returns HTTP 200. That ordering was
the one risk in the change, since EOS never revisits an "invalid" verdict.
Both certificates were self-signed and neither carried a CN matching the
Service, so the generated one was no better placed for a client that verifies.
ceos.restconfSslProfile is there for anyone who needs a real one: configure the
profile and name it. It is chart-wide because one startup-config ConfigMap is
shared by every cEOS node.
Removing the Job also removes the three traps it had to work around -- an
explicit 600s deadline instead of a backoffLimit that a slow boot loses,
--fail-with-body because curl exits 0 on the HTTP 404 nginx serves during boot,
and a test for "result" because eAPI reports a failed command inside an
HTTP 200. None of them are fixed; they stopped being reachable.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This was referenced Jul 31, 2026
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.
The defect
RESTCONF died on every container restart.
startup-configis a ConfigMap mounted at/mnt/flash/startup-configand survives anything; the certificate it named was written by the<node>-generate-certJob into the container's writable layer and did not. After a restart the profile referenced a file that no longer existed:EOS marked the profile invalid,
management api restconfreported "SSL profile not in valid state", and the Job was long sinceCompleteand never re-ran. Observed on a lab whose host sleeps nightly — the pods restart, and RESTCONF is gone every morning.v0.5.10fixed the ordering at install time. It could not fix this, because the defect is not ordering — it is that the config outlives the certificate it points at.The change
EOS generates a self-signed profile for itself, so pointing RESTCONF at
ARISTA_DEFAULT_SELF_SIGNED_PROFILEtakes the certificate out of the chart's concerns entirely. The Job and its ConfigMap are deleted.This is what
management api http-commandsalready did: eAPI names no profile, takes the EOS default, and that is precisely why eAPI on 443 kept working across restarts while RESTCONF did not. RESTCONF now behaves the same way rather than through a mechanism of its own.ceos.restconfSslProfileis there for anyone who needs a verifiable certificate: configure the profile and name it. Chart-wide, because onestartup-configConfigMap is shared by every cEOS node.Verification
Tested from a cold boot with no Job in the cluster — the pod was deleted and recreated from the new
startup-config:plus a real request between devices returning
HTTP 200.That ordering was the one risk in this change: if the built-in profile were not yet valid when EOS processes the
management api restconfline, we would have reproduced the original bug under a different profile name, since EOS never revisits an "invalid" verdict. It is valid in time.Also checked:
ARISTA_SELF_SIGNED.crthas different serial numbers on different devices, so EOS generates it per device rather than shipping it in the image.Notes
backoffLimita slow boot loses,--fail-with-bodybecausecurlexits 0 on the HTTP 404 nginx serves during boot, and a test for"result"because eAPI reports a failed command inside an HTTP 200. None are fixed — they stopped being reachable.ARISTA_DEFAULT_SELF_SIGNED_PROFILEexists there too.🤖 Generated with Claude Code