Pass --machine-type and --disable-autoconfig flags from driver to gcsfuse#553
Merged
hungnguyen243 merged 1 commit intoGoogleCloudPlatform:mainfrom May 5, 2025
Conversation
f545fec to
ad03a5f
Compare
e4f4e17 to
bbbfc2a
Compare
ca1f7eb to
48e275d
Compare
amacaskill
reviewed
Apr 30, 2025
amacaskill
reviewed
Apr 30, 2025
amacaskill
reviewed
Apr 30, 2025
amacaskill
reviewed
Apr 30, 2025
amacaskill
reviewed
Apr 30, 2025
amacaskill
reviewed
Apr 30, 2025
8746fc4 to
856e115
Compare
amacaskill
approved these changes
May 5, 2025
e8dc17d to
f87b315
Compare
amacaskill
reviewed
May 5, 2025
| } else { | ||
| klog.Warningf("Unable to fetch target node %v's machine type", node.Name) | ||
| } | ||
| // } |
Collaborator
There was a problem hiding this comment.
I think we can remove this
Contributor
Author
There was a problem hiding this comment.
Uncommented. This was left commented out during testing.
f87b315 to
0c700d8
Compare
amacaskill
reviewed
May 5, 2025
…gcsfuse to enable intelligent defaults for high-performance machine types
0c700d8 to
c649418
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.
What type of PR is this?
/kind feature
What this PR does / why we need it:
This PR bumped gcsfuse binary to v2.12.0-gke-0, where the the new two mountOptions start to be supported. Note that gcsfuse receives these flags but will not turn on the default values until v3.
Summary of changes:
As part of GCSFuse's intelligent defaults, new mountOption flags are supported: --machine-type and --disable-autoconfig.
We want to pass these two flags over from the driver to GCSFuse in the following mechanism:
Both flags are then written as a line-separated map to a temporary file under targetPath, which will be read by the sidecar container upon startup. The sidecar parses the file, reconstructs the map, and merges this map into the config file map. This approach is extensible, allowing us to add any new flag that we want to pass from the GCSFuse Driver container to the sidecar container and ultimately to the GCSFuse process.
Note that the PR also wraps the flag-writing logic on the driver behind a sidecar version filter, which checks that the sidecar container is a managed sidecar and on a compatible version (linked to a gcsfuse binary where the new flags are supported). This is to ensure that the file won't be unnecessarily written by the driver if not ultimately consumable by the sidecar (in the case of old/private sidecars). This minimum version is currently using a placeholder of v1.99.0-gke.0 in this PR, and we'll update this with the exact value after we completed the first round of release and get the corresponding sidecar image's version.
Testing:
Flag-passing functionality testing:
The PR has been tested both manually and with two new E2E tests by checking the GCSFuse config logged by the sidecar container:
I ran these E2E tests with driver code built without the sidecar version filter, and made sure they're WAI: https://paste.googleplex.com/4777435008335872
Sidecar version filter testing:
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Does this PR introduce a user-facing change?: