Added ability to create replica 3 arbiter 1 gluster volumes#48774
Added ability to create replica 3 arbiter 1 gluster volumes#48774rallytime merged 6 commits intosaltstack:developfrom
Conversation
salt/modules/glusterfs.py
Outdated
|
|
||
| def create_volume(name, bricks, stripe=False, replica=False, device_vg=False, | ||
| transport='tcp', start=False, force=False): | ||
| def create_volume(name, bricks, stripe=False, replica=False, arbiter=False, |
There was a problem hiding this comment.
Can you move the new kwarg to the end of the list? We don't want to create an API change with this new addition.
| Valid configuration limited to "replica 3 arbiter 1" per \ | ||
| Gluster documentation. Every third brick in the brick list \ | ||
| is used as an arbiter brick. | ||
|
|
There was a problem hiding this comment.
Can you add a .. versionadded:: Fluorine tag to these new docs?
There was a problem hiding this comment.
Done-ish? I wasn't 100% sure on the proper syntax for that tag. I added it just above the new documentation I added, but it looks slightly janky. Let me know if it's OK as-is, or if it should be done differently.
There was a problem hiding this comment.
Oh, you're close. It needs to be below the arg name. Something like this:
arbiter
words words words
.. versionadded:: Fluorine
There was a problem hiding this comment.
Ah! That looks much better. I tried putting it under initially, but didn't have a blank line after the "words words words" bit, so it didn't interpret it as a tag. Fixed now, thanks!
There was a problem hiding this comment.
Sure thing! Thanks for fixing this up so quickly!
salt/states/glusterfs.py
Outdated
| def volume_present(name, bricks, stripe=False, replica=False, device_vg=False, | ||
| transport='tcp', start=False, force=False): | ||
| def volume_present(name, bricks, stripe=False, replica=False, arbiter=False, | ||
| device_vg=False, transport='tcp', start=False, force=False): |
There was a problem hiding this comment.
Same comment here about the API change.
| replica count for volume | ||
|
|
||
| arbiter | ||
| use every third brick as arbiter (metadata only) |
There was a problem hiding this comment.
This needs a version tag too. :)
| Valid configuration limited to "replica 3 arbiter 1" per \ | ||
| Gluster documentation. Every third brick in the brick list \ | ||
| is used as an arbiter brick. | ||
|
|
There was a problem hiding this comment.
Sure thing! Thanks for fixing this up so quickly!
What does this PR do?
Adds the ability to create replica 3 arbiter 1 gluster volumes
What issues does this PR fix or reference?
#42955
Previous Behavior
Arbiter configuration was not exposed in glusterfs volume creation
New Behavior
Volumes can be created with arbiter (metadata-only replication) bricks
Tests written?
No
Commits signed with GPG?
No
Please review Salt's Contributing Guide for best practices.
See GitHub's page on GPG signing for more information about signing commits with GPG.