Skip to content

add support for directories and checking for free space - #51385

Merged
dwoz merged 4 commits into
saltstack:developfrom
maxim-sermin:disk-enhancements
Feb 15, 2019
Merged

add support for directories and checking for free space#51385
dwoz merged 4 commits into
saltstack:developfrom
maxim-sermin:disk-enhancements

Conversation

@maxim-sermin

Copy link
Copy Markdown
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

dwoz commented Feb 13, 2019

Copy link
Copy Markdown
Contributor

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

@maxim-sermin

Copy link
Copy Markdown
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.

4 participants