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.30] Fix issues loading data-dir value from env vars or dropin config files #10596

Merged
merged 3 commits into from
Jul 29, 2024

Conversation

brandond
Copy link
Member

Backport of #10591

Proposed Changes

  • Don't set K3S_DATA_DIR env var in self-extracting multicall wrapper
    This was only used to pass the bundled strongswan path through to the flannel ipsec backend, and is no longer needed. Ref: Initial encrypted network support #719
  • Add K3S_DATA_DIR as env var for --data-dir flag
  • Fix inconsistent loading of config dropins when config file does not exist
    configfilearg.FindString would silently skip parsing dropins if the main config file didn't exist. If a custom config file path was passed it would raise an error, but if we were parsing the default config file and it didn't exist it would just silently fail to load the dropins.

Types of Changes

bugfix

Verification

Includes tests

Testing

See linked issue

Linked Issues

User-Facing Change


Further Comments

This was only used to pass the bundled strongswan path through to the flannel ipsec backend, and is no longer needed. Ref: k3s-io#719

Signed-off-by: Brad Davidson <[email protected]>
…exist

FindString would silently skip parsing dropins if the main config file
didn't exist. If a custom config file path was passed it would raise an
error, but if we were parsing the default config file and it didn't
exist it would just silently fail to load the dropins.

Signed-off-by: Brad Davidson <[email protected]>
@brandond brandond requested a review from a team as a code owner July 29, 2024 22:07
Copy link

codecov bot commented Jul 29, 2024

Codecov Report

Attention: Patch coverage is 91.66667% with 3 lines in your changes missing coverage. Please review.

Project coverage is 43.27%. Comparing base (086d9ca) to head (cffe82e).

Files Patch % Lines
pkg/configfilearg/parser.go 91.17% 1 Missing and 2 partials ⚠️

❗ There is a different number of reports uploaded between BASE (086d9ca) and HEAD (cffe82e). Click for more details.

HEAD has 17 uploads less than BASE
Flag BASE (086d9ca) HEAD (cffe82e)
unittests 2 1
inttests 20 10
e2etests 12 6
Additional details and impacted files
@@               Coverage Diff                @@
##           release-1.30   #10596      +/-   ##
================================================
- Coverage         48.92%   43.27%   -5.66%     
================================================
  Files               179      179              
  Lines             14936    14929       -7     
================================================
- Hits               7308     6460     -848     
- Misses             6300     7281     +981     
+ Partials           1328     1188     -140     
Flag Coverage Δ
e2etests 36.05% <13.88%> (-9.60%) ⬇️
inttests 36.75% <30.55%> (+0.03%) ⬆️
unittests 13.36% <86.11%> (+0.01%) ⬆️

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 f646604 into k3s-io:release-1.30 Jul 29, 2024
29 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.

2 participants