Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[release-1.31] Backports for 2025-01 #11566

Merged
merged 15 commits into from
Jan 10, 2025

Conversation

@brandond brandond requested a review from a team as a code owner January 10, 2025 20:06
@brandond brandond force-pushed the 2025-01-backports_release-1.31 branch 2 times, most recently from 829d322 to 66cbf27 Compare January 10, 2025 20:52
galal-hussein and others added 15 commits January 10, 2025 22:06
Signed-off-by: galal-hussein <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit b474770)
Signed-off-by: Brad Davidson <[email protected]>
Expose actual error, so that we can tell if the deployment is not found or not ready/available

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 93e5483)
Signed-off-by: Brad Davidson <[email protected]>
Avoid "snapshot save already in progress" flake when snapshot reconcile from previous save is still in progress.

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 68fbd1a)
Signed-off-by: Brad Davidson <[email protected]>
k3s-io#11501
Signed-off-by: muicoder <[email protected]>
(cherry picked from commit 056cee8)
Signed-off-by: Brad Davidson <[email protected]>
The servers package, and router.go in particular, had become quite
large. Address this by moving some things out to separate packages:
* http request handlers all move to pkg/server/handlers.
* node password bootstrap auth handler goes into pkg/nodepassword with
  the other nodepassword code.

While we're at it, also be more consistent about calling variables that
hold a config.Control struct or reference `control` instead of `config` or `server`.

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 2e4e7cf)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 5b1d57f)
Signed-off-by: Brad Davidson <[email protected]>
Clients now generate keys client-side and send CSRs. If the server is down-level and sends a cert+key instead of just responding with a cert signed with the client's public key, we use the key from the server instead.

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit caeebc5)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 3653724)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit f8271d8)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 8f8cfb5)
Signed-off-by: Brad Davidson <[email protected]>
Convert nodepassword tests to use shared mocks

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit c20c063)
Signed-off-by: Brad Davidson <[email protected]>
Make this field an interface instead of pointer to allow mocking. Not sure why wrangler has a type that returns an interface instead of just making it an interface itself. Wrangler in general is hard to mock for testing.

Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit e632765)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit f345697)
Signed-off-by: Brad Davidson <[email protected]>
Signed-off-by: Brad Davidson <[email protected]>
(cherry picked from commit 9b1b90b)
Signed-off-by: Brad Davidson <[email protected]>
k3s-io#11501
Signed-off-by: muicoder <[email protected]>
(cherry picked from commit 0144d9b)
Signed-off-by: Brad Davidson <[email protected]>
@brandond brandond force-pushed the 2025-01-backports_release-1.31 branch from 66cbf27 to 9ae03e9 Compare January 10, 2025 22:06
Copy link

codecov bot commented Jan 10, 2025

Codecov Report

Attention: Patch coverage is 62.14689% with 335 lines in your changes missing coverage. Please review.

Project coverage is 44.45%. Comparing base (d0b42cc) to head (9ae03e9).
Report is 15 commits behind head on release-1.31.

Files with missing lines Patch % Lines
pkg/server/handlers/handlers.go 74.21% 49 Missing and 17 partials ⚠️
pkg/server/handlers/secrets-encrypt.go 7.81% 59 Missing ⚠️
pkg/agent/config/config.go 38.02% 25 Missing and 19 partials ⚠️
tests/mock/core.go 68.99% 34 Missing and 6 partials ⚠️
pkg/nodepassword/validate.go 75.37% 26 Missing and 7 partials ⚠️
pkg/daemons/control/server.go 67.27% 14 Missing and 4 partials ⚠️
pkg/server/handlers/cert.go 5.26% 18 Missing ⚠️
pkg/server/handlers/token.go 20.00% 14 Missing and 2 partials ⚠️
pkg/agent/flannel/setup.go 47.82% 8 Missing and 4 partials ⚠️
pkg/util/api.go 40.00% 8 Missing and 4 partials ⚠️
... and 7 more
Additional details and impacted files
@@               Coverage Diff                @@
##           release-1.31   #11566      +/-   ##
================================================
- Coverage         47.62%   44.45%   -3.17%     
================================================
  Files               181      184       +3     
  Lines             18794    19026     +232     
================================================
- Hits               8950     8458     -492     
- Misses             8499     9358     +859     
+ Partials           1345     1210     -135     
Flag Coverage Δ
e2etests 35.35% <50.40%> (-7.43%) ⬇️
inttests 34.88% <49.20%> (-0.02%) ⬇️
unittests 17.24% <47.00%> (+2.98%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@brandond brandond merged commit 594444e into k3s-io:release-1.31 Jan 10, 2025
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants