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

Fixes #18534: Skip non-standard moint FS for free-space check #3351

Conversation

ElaadF
Copy link
Member

@ElaadF ElaadF commented Nov 9, 2020

@ElaadF ElaadF requested a review from fanf November 9, 2020 16:28
@fanf
Copy link
Member

fanf commented Nov 9, 2020

No, you need to first filter to keep only lines starting with "/" and then keep the original logic of looking for "/var" or use "/"

Copy link
Member

@fanf fanf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, you need to first filter to keep only lines starting with "/" and then keep the original logic of looking for "/var" or use "/"

@ElaadF ElaadF force-pushed the ust_18534/skip_non_standard_moint_fs_for_free_space_check branch from dab3ecc to 39cf8fb Compare November 9, 2020 17:00
@ElaadF
Copy link
Member Author

ElaadF commented Nov 9, 2020

Commit modified

@@ -96,7 +96,7 @@ final object CheckFreeSpace extends Check {

def run: IOResult[HealthcheckResult] = {
val file = root / "proc" / "mounts"
val mountsContent = file.lines.map(x => x.split(" ")(1)).toList
val mountsContent = file.lines.filter(_(0) == '/').map(x => x.split(" ")(1)).toList
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you had a comment to explain? With a link to the bug for future reference ?

@ElaadF ElaadF force-pushed the ust_18534/skip_non_standard_moint_fs_for_free_space_check branch from 39cf8fb to f8a64ac Compare November 9, 2020 17:14
@ElaadF
Copy link
Member Author

ElaadF commented Nov 9, 2020

Commit modified

@ElaadF ElaadF requested a review from fanf November 9, 2020 17:17
@Normation-Quality-Assistant
Copy link
Contributor

OK, merging this PR

@Normation-Quality-Assistant Normation-Quality-Assistant merged commit 074ca8e into Normation:branches/rudder/6.2 Nov 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants