feat: add certificate renewal service#3523
Merged
reubenmiller merged 1 commit intothin-edge:mainfrom Apr 17, 2025
Merged
Conversation
Contributor
Robot Results
|
9552a12 to
b9b3b30
Compare
f14d88e to
d7d1970
Compare
d7d1970 to
ad9f465
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅ 📢 Thoughts on this report? Let us know! 🚀 New features to boost your workflow:
|
ad9f465 to
9e99075
Compare
didier-wenzek
approved these changes
Apr 17, 2025
Contributor
didier-wenzek
left a comment
There was a problem hiding this comment.
Approved. Nice to see that no more script is required to wrap tedge cert.
Comment on lines
+12
to
+13
| ; Always run the timer on time | ||
| AccuracySec=1us |
Contributor
There was a problem hiding this comment.
Surprising to have such a precise accuracy for randomized delays, but indeed recommended.
| Execute Command tedge reconnect c8y | ||
|
|
||
| # Enforce a renewal using the service | ||
| Execute Command sudo tedge config set certificate.validity.minimum_duration 365d |
Contributor
There was a problem hiding this comment.
Smart way to force a renewal without hacking the service nor the certificate :-)
Signed-off-by: reubenmiller <reuben.d.miller@gmail.com>
97cf9ea to
3b2217b
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.
Proposed changes
Add certificate renewal service which is a dependency of the tedge-mapper-c8y service (and its systemd template variant).
The renewal is called by the systemd components (timer and script), however a script has been created to reliably renew the certificate and verify it and roll back to the previous certificate if necessary.
Note: The certificate renewer service will be installed and enabled by default when using the tedge-mapper-c8y service. However the renewal will fail if the user has not activated the new Cumulocity certificate-authority feature.
Types of changes
Paste Link to the issue
Checklist
just prepare-devonce)just formatas mentioned in CODING_GUIDELINESjust checkas mentioned in CODING_GUIDELINESFurther comments