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

add support for directories and checking for free space #51385

Merged
merged 4 commits into from
Feb 15, 2019

Conversation

maxim-sermin
Copy link
Contributor

What does this PR do?

Expand the capabilities of the disk state.

What issues does this PR fix or reference?

None

Previous Behavior

The disk state was previously only capable of evaluating disk mounts and one could only specify the amount of used space to verify.

New Behavior

Now first the mounts are searched for the given name (previous behavior) and if no match is found, a directory with the specified name is checked as a fallback.
Additionally added the free parameter (which is false by default - backwards compatible) which treats the minimum and maximum parameters as the range of unutilized space.

Tests written?

Yes

Commits signed with GPG?

Yes

Please review Salt's Contributing Guide for best practices.

See GitHub's page on GPG signing for more information about signing commits with GPG.

@dwoz
Copy link
Contributor

dwoz commented Feb 13, 2019

@maxim-sermin The failing tests seem to be related to this change, can you look into them please?

@maxim-sermin
Copy link
Contributor Author

@dwoz I fixed the tests

@dwoz dwoz merged commit a8d7c0c into saltstack:develop Feb 15, 2019
garethgreenaway added a commit to garethgreenaway/salt that referenced this pull request Sep 19, 2019
dwoz added a commit that referenced this pull request Nov 14, 2019
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